Add facility to dump pass manager structure

to make it easier to understand failure.

llvm-svn: 40567
This commit is contained in:
Devang Patel 2007-07-27 20:06:09 +00:00
parent 35a77d857b
commit 780ecf20d1
2 changed files with 13 additions and 4 deletions

View File

@ -227,10 +227,7 @@ public:
/// Add RequiredPass into list of lower level passes required by pass P.
/// RequiredPass is run on the fly by Pass Manager when P requests it
/// through getAnalysis interface.
virtual void addLowerLevelRequiredPass(Pass *P, Pass *RequiredPass) {
assert (0 &&
"Unable to handle Pass that requires lower level Analysis pass");
}
virtual void addLowerLevelRequiredPass(Pass *P, Pass *RequiredPass);
virtual Pass * getOnTheFlyPass(Pass *P, const PassInfo *PI, Function &F) {
assert (0 && "Unable to find on the fly pass");

View File

@ -907,6 +907,18 @@ void PMDataManager::dumpAnalysisSetInfo(const char *Msg, Pass *P,
}
}
/// Add RequiredPass into list of lower level passes required by pass P.
/// RequiredPass is run on the fly by Pass Manager when P requests it
/// through getAnalysis interface.
/// This should be handled by specific pass manager.
void PMDataManager::addLowerLevelRequiredPass(Pass *P, Pass *RequiredPass) {
if (TPM) {
TPM->dumpArguments();
TPM->dumpPasses();
}
assert (0 && "Unable to handle Pass that requires lower level Analysis pass");
}
// Destructor
PMDataManager::~PMDataManager() {