in function MPPassManager::addLowerLevelRequiredPass in file LegacyPassManager.cpp, there is a memory leak found.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
If we add a pass twice into a ModulePass (for example, if a ModulePass depends on two FunctionPasses, and the second FunctionPass also depends on the first one), this leak can happen.
I think using unique_ptr can work, but need touch the key data structure of the pass management, and will be a much more complex fix.