diff options
author | Sanjoy Das <sanjoy@playingwithpointers.com> | 2017-03-03 18:53:09 +0000 |
---|---|---|
committer | Sanjoy Das <sanjoy@playingwithpointers.com> | 2017-03-03 18:53:09 +0000 |
commit | 0a4ec554c110f7914c659a0a551aeb0919930ca2 (patch) | |
tree | a1025974b281e60e006ae737c31c51b795e9f097 /llvm/lib/Transforms/Utils/LoopUnrollPeel.cpp | |
parent | d97381367a7f25267ab96658710113aa0687f420 (diff) | |
download | bcm5719-llvm-0a4ec554c110f7914c659a0a551aeb0919930ca2.tar.gz bcm5719-llvm-0a4ec554c110f7914c659a0a551aeb0919930ca2.zip |
Fix a compiler warning
llvm-svn: 296903
Diffstat (limited to 'llvm/lib/Transforms/Utils/LoopUnrollPeel.cpp')
-rw-r--r-- | llvm/lib/Transforms/Utils/LoopUnrollPeel.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Utils/LoopUnrollPeel.cpp b/llvm/lib/Transforms/Utils/LoopUnrollPeel.cpp index e45aef88722..55bfc25a086 100644 --- a/llvm/lib/Transforms/Utils/LoopUnrollPeel.cpp +++ b/llvm/lib/Transforms/Utils/LoopUnrollPeel.cpp @@ -80,7 +80,8 @@ void llvm::computePeelCount(Loop *L, unsigned LoopSize, // Iterate over Phis to find one with invariant input on back edge. bool FoundCandidate = false; PHINode *Phi; - for (auto BI = Header->begin(); Phi = dyn_cast<PHINode>(&*BI); ++BI) { + for (auto BI = Header->begin(); isa<PHINode>(&*BI); ++BI) { + Phi = cast<PHINode>(&*BI); Value *Input = Phi->getIncomingValueForBlock(BackEdge); if (L->isLoopInvariant(Input)) { FoundCandidate = true; |