diff --git a/lib/VMCore/PassManager.cpp b/lib/VMCore/PassManager.cpp index ae418a0b128..c07372c335a 100644 --- a/lib/VMCore/PassManager.cpp +++ b/lib/VMCore/PassManager.cpp @@ -738,9 +738,15 @@ void PMDataManager::removeNotPreservedAnalysis(Pass *P) { std::map::iterator Info = I++; if (!dynamic_cast(Info->second) && std::find(PreservedSet.begin(), PreservedSet.end(), Info->first) == - PreservedSet.end()) + PreservedSet.end()) { // Remove this analysis + if (PassDebugging >= Details) { + Pass *S = Info->second; + errs() << " -- '" << P->getPassName() << "' is not preserving '"; + errs() << S->getPassName() << "'\n"; + } InheritedAnalysis[Index]->erase(Info); + } } } }