[llvm-commits] [llvm] r56509 - /llvm/trunk/lib/CodeGen/DeadMachineInstructionElim.cpp

Dan Gohman gohman at apple.com
Tue Sep 23 15:04:18 PDT 2008


Author: djg
Date: Tue Sep 23 17:04:18 2008
New Revision: 56509

URL: http://llvm.org/viewvc/llvm-project?rev=56509&view=rev
Log:
Now that DeadMachineInstructionElim is basically working
correctly, it's not necessary to explicitly remove registers
from their use-def lists.

Modified:
    llvm/trunk/lib/CodeGen/DeadMachineInstructionElim.cpp

Modified: llvm/trunk/lib/CodeGen/DeadMachineInstructionElim.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/DeadMachineInstructionElim.cpp?rev=56509&r1=56508&r2=56509&view=diff

==============================================================================
--- llvm/trunk/lib/CodeGen/DeadMachineInstructionElim.cpp (original)
+++ llvm/trunk/lib/CodeGen/DeadMachineInstructionElim.cpp Tue Sep 23 17:04:18 2008
@@ -97,12 +97,6 @@
 
         // If there are no defs with uses, the instruction is dead.
         if (AllDefsDead) {
-          // Clear out the operands to take the registers out of their
-          // use chains.
-          while (unsigned Num = MI->getNumOperands())
-            MI->RemoveOperand(Num-1);
-
-          // Delete the actual instruction.
           AnyChanges = true;
           MI->eraseFromParent();
           MIE = MBB->rend();





More information about the llvm-commits mailing list