mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-05 02:16:46 +00:00
Now, there is additional layer, referred in the comment,
in place to handle this correctly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32684 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
b60528b8ab
commit
a68941b2d4
@ -153,10 +153,6 @@ public:
|
||||
/// then return NULL.
|
||||
Pass *findAnalysisPass(AnalysisID AID);
|
||||
|
||||
inline void clearManagers() {
|
||||
PassManagers.clear();
|
||||
}
|
||||
|
||||
virtual ~PMTopLevelManager() {
|
||||
for (std::vector<Pass *>::iterator I = PassManagers.begin(),
|
||||
E = PassManagers.end(); I != E; ++I)
|
||||
@ -1150,13 +1146,6 @@ FunctionPassManager::FunctionPassManager(ModuleProvider *P) {
|
||||
}
|
||||
|
||||
FunctionPassManager::~FunctionPassManager() {
|
||||
// Note : FPM maintains one entry in PassManagers vector.
|
||||
// This one entry is FPM itself. This is not ideal. One
|
||||
// alternative is have one additional layer between
|
||||
// FunctionPassManager and FunctionPassManagerImpl.
|
||||
// Meanwhile, to avoid going into infinte loop, first
|
||||
// remove FPM from its PassMangers vector.
|
||||
FPM->clearManagers();
|
||||
delete FPM;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user