[llvm] [AMDGPU] Add support for preloading implicit kernel arguments (PR #83817)

Austin Kerbow via llvm-commits llvm-commits at lists.llvm.org
Sun Jun 2 22:15:12 PDT 2024


================
@@ -3210,4 +3210,12 @@ def int_amdgcn_addrspacecast_nonnull : DefaultAttrsIntrinsic<
   [llvm_anyptr_ty], [llvm_anyptr_ty],
   [IntrNoMem, IntrSpeculatable]
 >;
+
+// This intrinsic is used to track the user SGPRs that hold implicit kernel
+// arguments. The i32 argument for this intrinsic represents the offset in
+// bytes from the value pointed to by the implicitarg pointer.
+def int_amdgcn_preload_implicitarg :
----------------
kerbowa wrote:

I believe rewriting the function signature in this way would be an ABI breaking change that would require coordination beyond the compiler.

Do you think that the current approach in this PR could be feasible in the meantime, or do you think that changing the handling of implicit arguments in this way is something we should move towards right away?

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


More information about the llvm-commits mailing list