[llvm] [AMDGPU] Add amdgcn.av.global.(load|store).b128 intrinsics (PR #191390)

Sameer Sahasrabuddhe via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 28 01:28:15 PDT 2026


================
@@ -902,6 +902,31 @@ def int_amdgcn_bitop3 :
                         [LLVMMatchType<0>, LLVMMatchType<0>, LLVMMatchType<0>, llvm_i32_ty],
                         [ImmArg<ArgIndex<3>>]>;
 
+class AMDGPUAVGlobalStore : Intrinsic <
+  [],
+  [global_ptr_ty,          // Base global pointer to store to
----------------
ssahasra wrote:

> > The established convention seems to keep each address space
> 
> If this is a synthetic compiler operation, it should look more like an IR load and less like an instruction intrinsic

There seems to be a limit to that resemblance. We can either use readable names like ".global" and ".flat" in the intrinsic name, or the declaration will be automatically mangled with ".p1" or ".p0" respectively. Also, I tried overloading the intrinsic declaration with "anyptr" type, but it fails to disambiguate between the two overloads. The logic to disambiguate based on pointer types seems specific to instructions and not intrinsics. 

https://github.com/llvm/llvm-project/pull/191390


More information about the llvm-commits mailing list