X-Git-Url: http://plrg.eecs.uci.edu/git/?p=oota-llvm.git;a=blobdiff_plain;f=lib%2FIR%2FVerifier.cpp;h=37b56f8efc769aa21cf0a96a2a13b9e899948714;hp=c8f99c5b4ccbe7143236c287772b1778816d7701;hb=70b36591bc9e9f0772c62794bf1a202b1884aaf6;hpb=4a0af1e1c440d155c7d9f234448dca7d5c8beddd diff --git a/lib/IR/Verifier.cpp b/lib/IR/Verifier.cpp index c8f99c5b4cc..37b56f8efc7 100644 --- a/lib/IR/Verifier.cpp +++ b/lib/IR/Verifier.cpp @@ -1974,6 +1974,10 @@ void Verifier::visitBasicBlock(BasicBlock &BB) { "PHI nodes must have at least one entry. If the block is dead, " "the PHI should be removed!", PN); + if (PN->getNumIncomingValues() != Preds.size()) { + dbgs() << "Problematic function: \n" << *PN->getParent()->getParent() << "\n"; + dbgs() << "Problematic block: \n" << *PN->getParent() << "\n"; + } Assert(PN->getNumIncomingValues() == Preds.size(), "PHINode should have one entry for each predecessor of its " "parent basic block!",