[llvm] [CodeGen] Notify delegate before erasing folded instruction (PR #222919)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 11 04:04:49 PDT 2026


================
@@ -339,10 +341,10 @@ void LiveRangeEdit::eliminateDeadDef(MachineInstr *MI, ToShrinkSet &ToShrink) {
     MI->setDesc(TII.get(TargetOpcode::KILL));
     // Remove all operands that aren't physregs.
     for (unsigned i = MI->getNumOperands(); i; --i) {
-      const MachineOperand &MO = MI->getOperand(i-1);
+      const MachineOperand &MO = MI->getOperand(i - 1);
       if (MO.isReg() && MO.getReg().isPhysical())
         continue;
-      MI->removeOperand(i-1);
+      MI->removeOperand(i - 1);
     }
----------------
arsenm wrote:

This patch is mostly formatting only changes which should be separate 

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


More information about the llvm-commits mailing list