[llvm] [AMDGPU][GlobalISel] Enable kernel argument preloading (PR #134655)

Austin Kerbow via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 24 21:55:18 PDT 2025


================
@@ -1297,10 +1295,9 @@ void AMDGPUTargetLowering::analyzeFormalArgumentsCompute(
 
       unsigned PartOffset = 0;
       for (unsigned i = 0; i != NumRegs; ++i) {
-        State.addLoc(CCValAssign::getCustomMem(InIndex++, RegisterVT,
-                                               BasePartOffset + PartOffset,
-                                               MemVT.getSimpleVT(),
-                                               CCValAssign::Full));
+        State.addLoc(CCValAssign::getCustomMem(
+            Arg.getArgNo(), RegisterVT, BasePartOffset + PartOffset,
----------------
kerbowa wrote:

Was ValNo just not used before and you have co-opt it to mean the original argument idx, or am I misunderstanding this change?

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


More information about the llvm-commits mailing list