Add a error message to cbu to match bu

llvm-svn: 28819
This commit is contained in:
Andrew Lenharth 2006-06-16 14:43:36 +00:00
parent fbee2e56cf
commit 0686842037
1 changed files with 7 additions and 1 deletions

View File

@ -56,8 +56,14 @@ bool CompleteBUDataStructures::runOnModule(Module &M) {
}
for (Module::iterator I = M.begin(), E = M.end(); I != E; ++I)
if (!I->isExternal() && !DSInfo.count(I))
if (!I->isExternal() && !DSInfo.count(I)) {
#ifndef NDEBUG
if (MainFunc)
std::cerr << "*** CBU: Function unreachable from main: "
<< I->getName() << "\n";
#endif
calculateSCCGraphs(getOrCreateGraph(*I), Stack, NextID, ValMap);
}
GlobalsGraph->removeTriviallyDeadNodes();