summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-02-14 20:14:17 +0000
committerChris Lattner <sabre@nondot.org>2006-02-14 20:14:17 +0000
commit94f936d8ef009cfcccf344590bea2177d809acad (patch)
tree04973b0f55fea082618fea1a2e4c4956acd6f034 /llvm/lib/Analysis
parentdb2a7a736ac774252bf170e3caa2050e75e71b72 (diff)
downloadbcm5719-llvm-94f936d8ef009cfcccf344590bea2177d809acad.tar.gz
bcm5719-llvm-94f936d8ef009cfcccf344590bea2177d809acad.zip
add an assert
llvm-svn: 26178
Diffstat (limited to 'llvm/lib/Analysis')
-rw-r--r--llvm/lib/Analysis/LoopInfo.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Analysis/LoopInfo.cpp b/llvm/lib/Analysis/LoopInfo.cpp
index 20b470f3eb4..2860aa492ce 100644
--- a/llvm/lib/Analysis/LoopInfo.cpp
+++ b/llvm/lib/Analysis/LoopInfo.cpp
@@ -367,7 +367,8 @@ BasicBlock *Loop::getLoopPreheader() const {
Out = *PI;
}
- // Make sure there is only one exit out of the preheader...
+ // Make sure there is only one exit out of the preheader.
+ assert(Out && "Header of loop has no predecessors from outside loop?");
succ_iterator SI = succ_begin(Out);
++SI;
if (SI != succ_end(Out))
OpenPOWER on IntegriCloud