[PATCH] D134423: [AMDGPU] Fix vgpr2sgpr copy to scalar operands of buffer instructions.

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 22 05:55:35 PDT 2022


arsenm added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/SIFixSGPRCopies.cpp:938
+
+  for (const auto &MO : MRI->reg_nodbg_operands(DefReg)) {
+    const auto *UseMI = MO.getParent();
----------------
The pass is already doing a walk over use operands, you shouldn't need another use list walk


================
Comment at: llvm/lib/Target/AMDGPU/SIFixSGPRCopies.cpp:949
+    // If MUBUF or MTBUF, use scalar register.
+    if (TII->isMUBUF(Opc) || TII->isMTBUF(Opc)) {
+      return true;
----------------
This is a property of specific operands


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D134423



More information about the llvm-commits mailing list