diff options
author | Gabor Greif <ggreif@gmail.com> | 2010-09-18 11:53:39 +0000 |
---|---|---|
committer | Gabor Greif <ggreif@gmail.com> | 2010-09-18 11:53:39 +0000 |
commit | aaa22cf1b698da2bb13a4a0dae1194f95c55d480 (patch) | |
tree | 4eca39f4165222516d6573b804101f423ec78f88 /llvm/lib/Transforms | |
parent | c44201c91e2ede0564d65401d79fde8986da5339 (diff) | |
download | bcm5719-llvm-aaa22cf1b698da2bb13a4a0dae1194f95c55d480.tar.gz bcm5719-llvm-aaa22cf1b698da2bb13a4a0dae1194f95c55d480.zip |
do not rely on the implicit-dereference semantics of dyn_cast_or_null
llvm-svn: 114277
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r-- | llvm/lib/Transforms/Scalar/IndVarSimplify.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp b/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp index af2eafc47cb..dfdd8b7c89f 100644 --- a/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp +++ b/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp @@ -346,7 +346,7 @@ void IndVarSimplify::RewriteNonIntegerIVs(Loop *L) { PHIs.push_back(PN); for (unsigned i = 0, e = PHIs.size(); i != e; ++i) - if (PHINode *PN = dyn_cast_or_null<PHINode>(PHIs[i])) + if (PHINode *PN = dyn_cast_or_null<PHINode>(&*PHIs[i])) HandleFloatingPointIV(L, PN); // If the loop previously had floating-point IV, ScalarEvolution @@ -395,7 +395,7 @@ void IndVarSimplify::EliminateIVComparisons() { // which are now dead. while (!DeadInsts.empty()) if (Instruction *Inst = - dyn_cast_or_null<Instruction>(DeadInsts.pop_back_val())) + dyn_cast_or_null<Instruction>(&*DeadInsts.pop_back_val())) RecursivelyDeleteTriviallyDeadInstructions(Inst); } @@ -462,7 +462,7 @@ void IndVarSimplify::EliminateIVRemainders() { // which are now dead. while (!DeadInsts.empty()) if (Instruction *Inst = - dyn_cast_or_null<Instruction>(DeadInsts.pop_back_val())) + dyn_cast_or_null<Instruction>(&*DeadInsts.pop_back_val())) RecursivelyDeleteTriviallyDeadInstructions(Inst); } @@ -725,7 +725,7 @@ void IndVarSimplify::RewriteIVExpressions(Loop *L, SCEVExpander &Rewriter) { // which are now dead. while (!DeadInsts.empty()) if (Instruction *Inst = - dyn_cast_or_null<Instruction>(DeadInsts.pop_back_val())) + dyn_cast_or_null<Instruction>(&*DeadInsts.pop_back_val())) RecursivelyDeleteTriviallyDeadInstructions(Inst); } |