@@ -334,6 +335,15 @@ template<> struct simplify_type {
}
};
+template <> struct GraphTraits {
wenju-he wrote:
> For the specific problem here, I'd consider expanding all constant
> expressions in the function upfront, and then not having to deal with it.
wenju-he wrote:
> I think it would be better if we could eliminate ConstantExpr addrspacecasts
> from the IR altogether, which would avoid most of the complexity here. I
> would also somewhat prefer to push this DFS into a helper function, but can
> live with it inline as-is
thank you for the
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/70611
>From 7c41be75c1ef661e757bfaca8d693b3937df649e Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Mon, 30 Oct 2023 08:36:52 +0800
Subject: [PATCH 1/2] [InferAddressSpaces] Fix constant replace to avoid
modifying oth
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/70611
>From 7c41be75c1ef661e757bfaca8d693b3937df649e Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Mon, 30 Oct 2023 08:36:52 +0800
Subject: [PATCH 1/3] [InferAddressSpaces] Fix constant replace to avoid
modifying oth
https://github.com/wenju-he ready_for_review
https://github.com/llvm/llvm-project/pull/70611
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,40 @@
+; RUN: opt -assume-default-is-flat-addrspace -print-module-scope
-print-after-all -S -disable-output -passes=infer-address-spaces <%s 2>&1 |
FileCheck %s
+
+; CHECK: IR Dump After InferAddressSpacesPass on f2
+
+; Check that after running infer-address-spaces o
@@ -0,0 +1,40 @@
+; RUN: opt -assume-default-is-flat-addrspace -print-module-scope
-print-after-all -S -disable-output -passes=infer-address-spaces <%s 2>&1 |
FileCheck %s
+
+; CHECK: IR Dump After InferAddressSpacesPass on f2
+
+; Check that after running infer-address-spaces o
@@ -334,6 +335,15 @@ template<> struct simplify_type {
}
};
+template <> struct GraphTraits {
wenju-he wrote:
> In any case, this should not be in a public IR header.
I've reverted the change in this file.
https://github.com/llvm/llvm-project/pull/70611
_
@@ -334,6 +335,15 @@ template<> struct simplify_type {
}
};
+template <> struct GraphTraits {
wenju-he wrote:
I measured llvm-project compile time impact of this change to llvm/IR/User.h on
intel icx 8358 cpu.
Build command:
`
cmake -GNinja -DLLVM_ENABLE_
https://github.com/wenju-he edited
https://github.com/llvm/llvm-project/pull/70611
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/wenju-he edited
https://github.com/llvm/llvm-project/pull/70611
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -334,6 +335,15 @@ template<> struct simplify_type {
}
};
+template <> struct GraphTraits {
wenju-he wrote:
added 3 more runs on RHEL9 today, the compile time diff is very small.
https://github.com/llvm/llvm-project/pull/70611
___
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/73887
>From e369b5d62094c9b48f3c33075d764c115a208a74 Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Thu, 30 Nov 2023 09:57:06 +0800
Subject: [PATCH] [IR] Disallow ZeroInit for spirv.Image
According to spirv spec, OpCo
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/73887
>From e369b5d62094c9b48f3c33075d764c115a208a74 Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Thu, 30 Nov 2023 09:57:06 +0800
Subject: [PATCH] [IR] Disallow ZeroInit for spirv.Image
According to spirv spec, OpCo
wenju-he wrote:
> image-unoptimized.ll
backtrace:
```
#0 0x01d2f0e1 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int)
(/export/users/wenjuhe/llvm/llvm-project/build/bin/llc+0x1d2f0e1)
#1 0x01d2c644 SignalHandler(int) Signals.cpp:0:0
#2 0x7fd516a7ddb0 __restore_rt (/lib6
https://github.com/wenju-he created
https://github.com/llvm/llvm-project/pull/130755
In libclc, we observe that compiling OpenCL source files to bitcode is executed
sequentially on Windows, which increases debug build time by about an hour.
add_custom_command may introduce additional implicit d
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/130755
>From 1f8b5bfbfea6b562e9cae088256e8e5dddf0a335 Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Tue, 11 Mar 2025 04:24:36 -0700
Subject: [PATCH 1/2] [libclc] Fix commands in compile_to_bc are executed
sequentiall
wenju-he wrote:
@frasercrmck could you please review? thanks
https://github.com/llvm/llvm-project/pull/130755
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/wenju-he created
https://github.com/llvm/llvm-project/pull/130882
When the flag is empty, the opt command won't modify the bitcode; however, the
command is slow for large bitcode files in debug mode.
>From 1727cb49ebbee324ecad0a766ec341eb1aed082b Mon Sep 17 00:00:00 2001
Fro
wenju-he wrote:
@frasercrmck could you please review? thanks
https://github.com/llvm/llvm-project/pull/130882
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
wenju-he wrote:
@frasercrmck could you please review? thanks
https://github.com/llvm/llvm-project/pull/130871
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/130882
>From 1727cb49ebbee324ecad0a766ec341eb1aed082b Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Tue, 11 Mar 2025 19:05:25 -0700
Subject: [PATCH 1/4] [libclc] Skip opt command if opt_flags is empty
When the flag i
wenju-he wrote:
> Am I right in thinking that CMake 3.27's `DEPENDS_EXPLICIT_ONLY` would also
> fix this? If so it might be worth documenting this explicitly, both in the
> PR/commit and in the code? We might be able to refactor this in the future,
> when LLVM updates its minimum version to 3.
https://github.com/wenju-he edited
https://github.com/llvm/llvm-project/pull/130882
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/130882
>From 1727cb49ebbee324ecad0a766ec341eb1aed082b Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Tue, 11 Mar 2025 19:05:25 -0700
Subject: [PATCH 1/5] [libclc] Skip opt command if opt_flags is empty
When the flag i
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/130755
>From 1f8b5bfbfea6b562e9cae088256e8e5dddf0a335 Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Tue, 11 Mar 2025 04:24:36 -0700
Subject: [PATCH 1/3] [libclc] Fix commands in compile_to_bc are executed
sequentiall
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/130882
>From 1727cb49ebbee324ecad0a766ec341eb1aed082b Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Tue, 11 Mar 2025 19:05:25 -0700
Subject: [PATCH 1/2] [libclc] Skip opt command if opt_flags is empty
When the flag i
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/130882
>From 1727cb49ebbee324ecad0a766ec341eb1aed082b Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Tue, 11 Mar 2025 19:05:25 -0700
Subject: [PATCH 1/3] [libclc] Skip opt command if opt_flags is empty
When the flag i
@@ -342,21 +342,32 @@ function(add_libclc_builtin_set)
set( builtins_opt_lib_tgt builtins.opt.${ARG_ARCH_SUFFIX} )
- # Add opt target
- add_custom_command( OUTPUT ${builtins_opt_lib_tgt}.bc
-COMMAND ${opt_exe} ${ARG_OPT_FLAGS} -o ${builtins_opt_lib_tgt}.bc
- ${bu
wenju-he wrote:
> Another option would be to unconditionally have builtin.opt targets but if no
> flags are passed, just make them empty targets that rely only on builtin.link
> targets.
Thanks for the suggestion. Done. Please review again.
https://github.com/llvm/llvm-project/pull/130882
__
https://github.com/wenju-he edited
https://github.com/llvm/llvm-project/pull/130755
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/132338
>From 6ce54aa767f8cdff2f938cdce8656e495a1346f0 Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Thu, 20 Mar 2025 22:01:55 -0700
Subject: [PATCH 1/2] [libclc] link_bc target should depends on target
builtins.link.
@@ -342,22 +342,32 @@ function(add_libclc_builtin_set)
set( builtins_opt_lib_tgt builtins.opt.${ARG_ARCH_SUFFIX} )
- # Add opt target
- add_custom_command( OUTPUT ${builtins_opt_lib_tgt}.bc
-COMMAND ${opt_exe} ${ARG_OPT_FLAGS} -o ${builtins_opt_lib_tgt}.bc
- ${bu
@@ -313,8 +314,8 @@ function(add_libclc_builtin_set)
INTERNALIZE
TARGET ${builtins_link_lib_tgt}
INPUTS $
-${ARG_INTERNAL_LINK_DEPENDENCIES}
- DEPENDENCIES ${builtins_link_lib_tmp_tgt}
+$
wenju-he wrote:
thanks, changed t
wenju-he wrote:
@frasercrmck could you please try this PR on https://github.com/intel/llvm repo?
My experiment:
clang --version
clang version 21.0.0git (https://github.com/llvm/llvm-project
f5ee10538b68835112323c241ca7db67ca78bf62)
before PR:
find . -name "builtins.link*.bc" -printf "%s\n" |
@@ -342,22 +342,32 @@ function(add_libclc_builtin_set)
set( builtins_opt_lib_tgt builtins.opt.${ARG_ARCH_SUFFIX} )
- # Add opt target
- add_custom_command( OUTPUT ${builtins_opt_lib_tgt}.bc
-COMMAND ${opt_exe} ${ARG_OPT_FLAGS} -o ${builtins_opt_lib_tgt}.bc
- ${bu
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/132338
>From 6ce54aa767f8cdff2f938cdce8656e495a1346f0 Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Thu, 20 Mar 2025 22:01:55 -0700
Subject: [PATCH] [libclc] link_bc target should depends on target
builtins.link.clc-
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/130882
>From 1727cb49ebbee324ecad0a766ec341eb1aed082b Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Tue, 11 Mar 2025 19:05:25 -0700
Subject: [PATCH 1/6] [libclc] Skip opt command if opt_flags is empty
When the flag i
wenju-he wrote:
I've tested on Windows for half a day, it seems this PR can fix the issue.
https://github.com/llvm/llvm-project/pull/132338
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm
https://github.com/wenju-he edited
https://github.com/llvm/llvm-project/pull/132338
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
wenju-he wrote:
@frasercrmck could you please review? thanks
https://github.com/llvm/llvm-project/pull/132338
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
wenju-he wrote:
@frasercrmck please help to merge, thanks. I don't have merge access.
https://github.com/llvm/llvm-project/pull/130882
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -211,8 +211,9 @@ endfunction()
# * ALIASES ...
# List of aliases
# * INTERNAL_LINK_DEPENDENCIES ...
wenju-he wrote:
done
https://github.com/llvm/llvm-project/pull/132338
___
cfe-commits mailing list
cfe-
https://github.com/wenju-he created
https://github.com/llvm/llvm-project/pull/132338
Currently link_bc command depends on the bitcode file that is associated with
custom target builtins.link.clc-arch_suffix.
On windows we randomly see following error:
`
Generating builtins.link.clc-${ARCH}--.
@@ -342,22 +342,32 @@ function(add_libclc_builtin_set)
set( builtins_opt_lib_tgt builtins.opt.${ARG_ARCH_SUFFIX} )
- # Add opt target
- add_custom_command( OUTPUT ${builtins_opt_lib_tgt}.bc
-COMMAND ${opt_exe} ${ARG_OPT_FLAGS} -o ${builtins_opt_lib_tgt}.bc
- ${bu
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/132338
>From 6ce54aa767f8cdff2f938cdce8656e495a1346f0 Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Thu, 20 Mar 2025 22:01:55 -0700
Subject: [PATCH 1/3] [libclc] link_bc target should depends on target
builtins.link.
wenju-he wrote:
@frasercrmck should we check CMAKE_VERSION and use DEPENDS_EXPLICIT_ONLY if the
version is 3.27 or higher? I suppose DEPENDS_EXPLICIT_ONLY would be more
light-weighted. And we need to keep both DEPENDS_EXPLICIT_ONLY and adding new
target path, until llvm uplifts cmake version t
https://github.com/wenju-he created
https://github.com/llvm/llvm-project/pull/134529
None
>From ac389b8b92fbb77c8884515d8f7293b4af17dfa5 Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Sun, 6 Apr 2025 18:30:42 +0800
Subject: [PATCH] [clang-format] Add 'cl' to enable OpenCL kernel file
formattin
https://github.com/wenju-he edited
https://github.com/llvm/llvm-project/pull/134529
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/wenju-he updated
https://github.com/llvm/llvm-project/pull/130755
>From 1f8b5bfbfea6b562e9cae088256e8e5dddf0a335 Mon Sep 17 00:00:00 2001
From: Wenju He
Date: Tue, 11 Mar 2025 04:24:36 -0700
Subject: [PATCH 1/4] [libclc] Fix commands in compile_to_bc are executed
sequentiall
@@ -283,7 +294,7 @@ function(add_libclc_builtin_set)
set( builtins_comp_lib_tgt builtins.comp.${ARG_ARCH_SUFFIX} )
add_custom_target( ${builtins_comp_lib_tgt}
-DEPENDS ${bytecode_files}
+DEPENDS ${compile_tgts}
wenju-he wrote:
thanks, I'll add ${b
https://github.com/wenju-he created
https://github.com/llvm/llvm-project/pull/134489
Similar to how cl_khr_fp64 and cl_khr_fp16 implementations are put in a same
file for math built-ins, this PR do the same to atom_* built-ins.
The main motivation is to prevent that two files with same base na
wenju-he wrote:
@frasercrmck could you please review, thanks.
https://github.com/llvm/llvm-project/pull/134489
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
53 matches
Mail list logo