summaryrefslogtreecommitdiff
path: root/lib/Analysis/ScalarEvolutionExpander.cpp
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2011-07-16 22:26:27 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2011-07-16 22:26:27 +0000
commit93a896e2e36480d55de3bab53e68581e08526344 (patch)
tree12369c86437b25477df7d507cff9946025f8941f /lib/Analysis/ScalarEvolutionExpander.cpp
parent975eb99cf3e3efaf83cfeddde982800d6a84f704 (diff)
downloadllvm-93a896e2e36480d55de3bab53e68581e08526344.tar.gz
llvm-93a896e2e36480d55de3bab53e68581e08526344.tar.bz2
llvm-93a896e2e36480d55de3bab53e68581e08526344.tar.xz
Silence compiler warnings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135358 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/ScalarEvolutionExpander.cpp')
-rw-r--r--lib/Analysis/ScalarEvolutionExpander.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/Analysis/ScalarEvolutionExpander.cpp b/lib/Analysis/ScalarEvolutionExpander.cpp
index 478f555fec..befe6d2599 100644
--- a/lib/Analysis/ScalarEvolutionExpander.cpp
+++ b/lib/Analysis/ScalarEvolutionExpander.cpp
@@ -849,7 +849,7 @@ SCEVExpander::getAddRecExprPHILiterally(const SCEVAddRecExpr *Normalized,
const Loop *L,
const Type *ExpandTy,
const Type *IntTy) {
- assert(!IVIncInsertLoop || IVIncInsertPos && "Uninitialized insert position");
+ assert((!IVIncInsertLoop||IVIncInsertPos) && "Uninitialized insert position");
// Reuse a previously-inserted PHI, if present.
for (BasicBlock::iterator I = L->getHeader()->begin();
@@ -926,10 +926,9 @@ SCEVExpander::getAddRecExprPHILiterally(const SCEVAddRecExpr *Normalized,
L->getHeader()->begin());
// StartV must be hoisted into L's preheader to dominate the new phi.
- Instruction *StartI = dyn_cast<Instruction>(StartV);
- assert(!StartI || SE.DT->properlyDominates(StartI->getParent(),
- L->getHeader()) && "");
- (void)StartI;
+ assert(!isa<Instruction>(StartV) ||
+ SE.DT->properlyDominates(cast<Instruction>(StartV)->getParent(),
+ L->getHeader()));
// Expand code for the step value. Insert instructions right before the
// terminator corresponding to the back-edge. Do this before creating the PHI