[clang] [llvm] [SPIR-V] Add clang builtin for group-wide barrier (PR #175064)
Joseph Huber via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 8 12:41:56 PST 2026
================
@@ -133,8 +133,8 @@ def int_spv_rsqrt : DefaultAttrsIntrinsic<[LLVMMatchType<0>], [llvm_anyfloat_ty]
: DefaultAttrsIntrinsic<[llvm_i32_ty], [], [IntrConvergent]>;
def int_spv_sign : DefaultAttrsIntrinsic<[LLVMScalarOrSameVectorWidth<0, llvm_i32_ty>], [llvm_any_ty], [IntrNoMem]>;
def int_spv_radians : DefaultAttrsIntrinsic<[LLVMMatchType<0>], [llvm_anyfloat_ty], [IntrNoMem]>;
- def int_spv_group_memory_barrier_with_group_sync
- : DefaultAttrsIntrinsic<[], [], [IntrConvergent]>;
+ def int_spv_group_memory_barrier_with_group_sync : ClangBuiltin<"__builtin_spirv_group_barrier">,
----------------
jhuber6 wrote:
I was considering adding a new one, because this one hard codes in the group scope and `seq_cst` ordering, but I figured the chance of someone needing something different is pretty low and this is less intrusive.
https://github.com/llvm/llvm-project/pull/175064
More information about the llvm-commits
mailing list