[llvm-commits] [llvm] r114278 - /llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp

Gabor Greif ggreif at gmail.com
Sat Sep 18 04:55:34 PDT 2010


Author: ggreif
Date: Sat Sep 18 06:55:34 2010
New Revision: 114278

URL: http://llvm.org/viewvc/llvm-project?rev=114278&view=rev
Log:
do not rely on the implicit-dereference semantics of dyn_cast_or_null

Modified:
    llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp

Modified: llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp?rev=114278&r1=114277&r2=114278&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/LoopStrengthReduce.cpp Sat Sep 18 06:55:34 2010
@@ -608,7 +608,7 @@
   bool Changed = false;
 
   while (!DeadInsts.empty()) {
-    Instruction *I = dyn_cast_or_null<Instruction>(DeadInsts.pop_back_val());
+    Instruction *I = dyn_cast_or_null<Instruction>(&*DeadInsts.pop_back_val());
 
     if (I == 0 || !isInstructionTriviallyDead(I))
       continue;





More information about the llvm-commits mailing list