[llvm] [AMDGPU] Add support for preloading implicit kernel arguments (PR #83817)
Austin Kerbow via llvm-commits
llvm-commits at lists.llvm.org
Sun May 12 22:03:32 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:
Am I understanding correctly that you think implicit hidden arguments should be added to the function signature in some way? Or what do you mean by "IR pass marking the inreg arguments to replace the load uses with the direct argument use". Maybe that should just be done in the frontend instead of just an IR pass since that is where this lowering to loads is currently happening. I mean it makes sense to me that they should be actual arguments but I'm not sure about the consequences of doing that.
https://github.com/llvm/llvm-project/pull/83817
More information about the llvm-commits
mailing list