mirror of
https://github.com/RPCSX/llvm.git
synced 2025-01-25 13:45:34 +00:00
Initialize AnalysisImpls for each pass before executing the pass.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32509 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
27aaab2bd3
commit
41545fd663
@ -768,7 +768,7 @@ BasicBlockPassManager_New::runOnFunction(Function &F) {
|
||||
for (std::vector<Pass *>::iterator itr = passVectorBegin(),
|
||||
e = passVectorEnd(); itr != e; ++itr) {
|
||||
Pass *P = *itr;
|
||||
|
||||
initializeAnalysisImpl(P);
|
||||
BasicBlockPass *BP = dynamic_cast<BasicBlockPass*>(P);
|
||||
Changed |= BP->runOnBasicBlock(*I);
|
||||
removeNotPreservedAnalysis(P);
|
||||
@ -977,7 +977,7 @@ bool FunctionPassManagerImpl_New::runOnFunction(Function &F) {
|
||||
for (std::vector<Pass *>::iterator itr = passVectorBegin(),
|
||||
e = passVectorEnd(); itr != e; ++itr) {
|
||||
Pass *P = *itr;
|
||||
|
||||
initializeAnalysisImpl(P);
|
||||
FunctionPass *FP = dynamic_cast<FunctionPass*>(P);
|
||||
Changed |= FP->runOnFunction(F);
|
||||
removeNotPreservedAnalysis(P);
|
||||
@ -1104,7 +1104,7 @@ ModulePassManager_New::runOnModule(Module &M) {
|
||||
for (std::vector<Pass *>::iterator itr = passVectorBegin(),
|
||||
e = passVectorEnd(); itr != e; ++itr) {
|
||||
Pass *P = *itr;
|
||||
|
||||
initializeAnalysisImpl(P);
|
||||
ModulePass *MP = dynamic_cast<ModulePass*>(P);
|
||||
Changed |= MP->runOnModule(M);
|
||||
removeNotPreservedAnalysis(P);
|
||||
|
Loading…
x
Reference in New Issue
Block a user