Commit 87abe2a3 authored by 4ast's avatar 4ast Committed by GitHub

Merge pull request #1259 from iovisor/yhs_dev

Fix a clang memory leak
parents f4727f43 6ed2229d
......@@ -296,6 +296,7 @@ int ClangLoader::parse(unique_ptr<llvm::Module> *mod, TableStorage &ts, const st
invocation2.getFrontendOpts().Inputs.push_back(FrontendInputFile(
main_path, FrontendOptions::getInputKindForExtension("c")));
invocation2.getFrontendOpts().DisableFree = false;
invocation2.getCodeGenOpts().DisableFree = false;
// Resort to normal inlining. In -O0 the default is OnlyAlwaysInlining and
// clang might add noinline attribute even for functions with inline hint.
invocation2.getCodeGenOpts().setInlining(CodeGenOptions::NormalInlining);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment