search for: asmundefinedref

Displaying 1 result from an estimated 1 matches for "asmundefinedref".

Did you mean: asmundefinedrefs
2014 Jan 22
2
[LLVMdev] [RFC] LTO: deallocating llvm::Module inside lto_codegen_add_module
...TO/LTOCodeGenerator.cpp index cae0ea2..a947fa8 100644 --- a/lib/LTO/LTOCodeGenerator.cpp +++ b/lib/LTO/LTOCodeGenerator.cpp @@ -121,6 +121,8 @@ bool LTOCodeGenerator::addModule(LTOModule* mod, std::string& errMsg) { for (int i = 0, e = undefs.size(); i != e; ++i) AsmUndefinedRefs[undefs[i]] = 1; + mod->destroyLLVMModule(); + return !ret; } With this change, the ownership of the llvm::Module and llvm::TargetMachine is being transferred from the LTOModule to the LTOCodeGenerator. Practically, this would decouple the deallocation of the main co...