summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2008-09-24 00:07:08 +0000
committerDan Gohman <gohman@apple.com>2008-09-24 00:07:08 +0000
commit1e2b282be3f553e3b57641e388a09c77134c8a0c (patch)
treea2fbf6d602f9533f1947a3f1238324ccac887b53 /llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
parent7c59ed6ff820ad834c7f72c69b92cafb569a1ee1 (diff)
downloadbcm5719-llvm-1e2b282be3f553e3b57641e388a09c77134c8a0c.tar.gz
bcm5719-llvm-1e2b282be3f553e3b57641e388a09c77134c8a0c.zip
Set SetStore to false, to allow this pass to delete
dead loads. llvm-svn: 56529
Diffstat (limited to 'llvm/lib/CodeGen/DeadMachineInstructionElim.cpp')
-rw-r--r--llvm/lib/CodeGen/DeadMachineInstructionElim.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp b/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
index c3cdbf02597..392e3b1b778 100644
--- a/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
+++ b/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
@@ -46,7 +46,7 @@ bool DeadMachineInstructionElim::runOnMachineFunction(MachineFunction &MF) {
const MachineRegisterInfo &MRI = MF.getRegInfo();
const TargetInstrInfo &TII = *MF.getTarget().getInstrInfo();
BitVector LivePhysRegs;
- bool SawStore = true;
+ bool SawStore;
// Compute a bitvector to represent all non-allocatable physregs.
BitVector NonAllocatableRegs = TRI.getAllocatableSet(MF);
@@ -79,6 +79,7 @@ bool DeadMachineInstructionElim::runOnMachineFunction(MachineFunction &MF) {
MachineInstr *MI = &*MII;
// Don't delete instructions with side effects.
+ SawStore = false;
if (MI->isSafeToMove(&TII, SawStore)) {
// Examine each operand.
bool AllDefsDead = true;
OpenPOWER on IntegriCloud