[PATCH] D121491: [AMDGPU] Restrict machine copy propagation from creating unaligned classes

Stanislav Mekhanoshin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 11 14:41:34 PST 2022


rampitec added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/SIInstrInfo.cpp:4774
+  const TargetRegisterClass *RC = RI.getRegClass(RCID);
+  if (RC && ST.needsAlignedVGPRs()) {
+    unsigned Size = RI.getRegSizeInBits(*RC);
----------------
arsenm wrote:
> Why can't you just select the aligned class above to begin with?
This is only VGPRs, and not all VGPRs. Then it will use a condition at every case, while the code below is still needed.


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

https://reviews.llvm.org/D121491



More information about the llvm-commits mailing list