From b2c3e3fdd9987fc2d08eb8f7892db2cbc7ec74d9 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Tue, 23 Sep 2008 22:04:18 +0000 Subject: [PATCH] Now that DeadMachineInstructionElim is basically working correctly, it's not necessary to explicitly remove registers from their use-def lists. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56509 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/DeadMachineInstructionElim.cpp | 6 ------ 1 file changed, 6 deletions(-) diff --git a/lib/CodeGen/DeadMachineInstructionElim.cpp b/lib/CodeGen/DeadMachineInstructionElim.cpp index 8f4162f5f23..c3cdbf02597 100644 --- a/lib/CodeGen/DeadMachineInstructionElim.cpp +++ b/lib/CodeGen/DeadMachineInstructionElim.cpp @@ -97,12 +97,6 @@ bool DeadMachineInstructionElim::runOnMachineFunction(MachineFunction &MF) { // 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();