[llvm-commits] CVS: llvm/lib/Transforms/Utils/Local.cpp

Chris Lattner lattner at cs.uiuc.edu
Mon Feb 24 14:49:03 PST 2003


Changes in directory llvm/lib/Transforms/Utils:

Local.cpp updated: 1.4 -> 1.5

---
Log message:

Rename Instruction::hasSideEffects() -> mayWriteToMemory()


---
Diffs of the changes:

Index: llvm/lib/Transforms/Utils/Local.cpp
diff -u llvm/lib/Transforms/Utils/Local.cpp:1.4 llvm/lib/Transforms/Utils/Local.cpp:1.5
--- llvm/lib/Transforms/Utils/Local.cpp:1.4	Tue Jun 25 11:12:51 2002
+++ llvm/lib/Transforms/Utils/Local.cpp	Mon Feb 24 14:48:32 2003
@@ -91,7 +91,7 @@
 //
 
 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





More information about the llvm-commits mailing list