[llvm] 8e1e1ad - AMDGPU: Use use_nodbg_instructions in GCNSchedStrategy MFMA check (#219403)

via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 28 01:24:57 PDT 2026


Author: Matt Arsenault
Date: 2026-08-28T10:24:52+02:00
New Revision: 8e1e1adf80defa5da75334400234331c33e67df6

URL: https://github.com/llvm/llvm-project/commit/8e1e1adf80defa5da75334400234331c33e67df6
DIFF: https://github.com/llvm/llvm-project/commit/8e1e1adf80defa5da75334400234331c33e67df6.diff

LOG: AMDGPU: Use use_nodbg_instructions in GCNSchedStrategy MFMA check (#219403)

Added: 
    

Modified: 
    llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp b/llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp
index efcfa4aae3870..0495b96706d61 100644
--- a/llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp
+++ b/llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp
@@ -2381,8 +2381,8 @@ bool RewriteMFMAFormStage::isRewriteCandidate(MachineInstr *MI) const {
     return false;
   // Reject candidates whose users force an unavoidable bridge copy.
   Register DstReg = MI->getOperand(0).getReg();
-  for (const MachineOperand &Use : DAG.MRI.use_nodbg_operands(DstReg)) {
-    if (!TII->isMAI(*Use.getParent()) && !Use.getParent()->isCopy())
+  for (const MachineInstr &UseMI : DAG.MRI.use_nodbg_instructions(DstReg)) {
+    if (!TII->isMAI(UseMI) && !UseMI.isCopy())
       return false;
   }
   return true;


        


More information about the llvm-commits mailing list