[PATCH] D63851: [AMDGPU] Packed thread ids in function call ABI

Stanislav Mekhanoshin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 26 17:45:44 PDT 2019


rampitec marked an inline comment as done.
rampitec added inline comments.


================
Comment at: lib/Target/AMDGPU/SIISelLowering.cpp:1643
                                       SIMachineFunctionInfo &Info) {
-  if (Info.hasWorkItemIDX())
-    Info.setWorkItemIDX(allocateVGPR32Input(CCInfo));
+  const unsigned Mask = 0x3ff;
+  ArgDescriptor Arg;
----------------
arsenm wrote:
> This should be derived from the subtarget maximum workgroup size
It is derived from the theoretical maximum you can pack into 32 bit register (and agrees with maximum whg size as well of course, which makes it possible).


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D63851/new/

https://reviews.llvm.org/D63851





More information about the llvm-commits mailing list