summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR/LegacyPassManager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/IR/LegacyPassManager.cpp')
-rw-r--r--llvm/lib/IR/LegacyPassManager.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/IR/LegacyPassManager.cpp b/llvm/lib/IR/LegacyPassManager.cpp
index 54d602d926e..d11a2b3c01a 100644
--- a/llvm/lib/IR/LegacyPassManager.cpp
+++ b/llvm/lib/IR/LegacyPassManager.cpp
@@ -677,6 +677,8 @@ void PMTopLevelManager::schedulePass(Pass *P) {
// available at this point.
const PassInfo *PI = findAnalysisPassInfo(P->getPassID());
if (PI && PI->isAnalysis() && findAnalysisPass(P->getPassID())) {
+ // Remove any cached AnalysisUsage information.
+ AnUsageMap.erase(P);
delete P;
return;
}
OpenPOWER on IntegriCloud