diff options
Diffstat (limited to 'lib/Transforms/Utils/Local.cpp')
-rw-r--r-- | lib/Transforms/Utils/Local.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Transforms/Utils/Local.cpp b/lib/Transforms/Utils/Local.cpp index 10028bacec..8f67e111a7 100644 --- a/lib/Transforms/Utils/Local.cpp +++ b/lib/Transforms/Utils/Local.cpp @@ -91,7 +91,7 @@ bool ConstantFoldTerminator(BasicBlock *BB) { // bool isInstructionTriviallyDead(Instruction *I) { - return I->use_empty() && !I->hasSideEffects() && !isa<TerminatorInst>(I); + return I->use_empty() && !I->mayWriteToMemory() && !isa<TerminatorInst>(I); } // dceInstruction - Inspect the instruction at *BBI and figure out if it's |