mirror of
https://github.com/postgres/postgres.git
synced 2025-06-26 12:21:12 +03:00
LLVMJIT: Free created module in LLVM < 5.
Due to the differing APIs between versions, I forgot to deallocate the generated module in older LLVM versions, leading to a memory leak. Author: Andres Freund
This commit is contained in:
@ -531,6 +531,7 @@ llvm_compile_module(LLVMJitContext *context)
|
|||||||
{
|
{
|
||||||
orc_handle = LLVMOrcAddEagerlyCompiledIR(compile_orc, context->module,
|
orc_handle = LLVMOrcAddEagerlyCompiledIR(compile_orc, context->module,
|
||||||
llvm_resolve_symbol, NULL);
|
llvm_resolve_symbol, NULL);
|
||||||
|
LLVMDisposeModule(context->module);
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user