Skip to content

Commit

Permalink
[examples][ORC] Add missing call to LLVMDisposeBuilder to example.
Browse files Browse the repository at this point in the history
The missing call was pointed out in https://llvm.org/PR56953, though it's not
the focus of that issue.
  • Loading branch information
lhames committed Aug 5, 2022
1 parent 51bc82d commit 4246269
Showing 1 changed file with 1 addition and 0 deletions.
Expand Up @@ -47,6 +47,7 @@ LLVMOrcThreadSafeModuleRef createDemoModule(void) {
LLVMValueRef SumArg1 = LLVMGetParam(SumFunction, 1);
LLVMValueRef Result = LLVMBuildAdd(Builder, SumArg0, SumArg1, "result");
LLVMBuildRet(Builder, Result);
LLVMDisposeBuilder(Builder);
LLVMOrcThreadSafeModuleRef TSM = LLVMOrcCreateNewThreadSafeModule(M, TSCtx);
LLVMOrcDisposeThreadSafeContext(TSCtx);
return TSM;
Expand Down

0 comments on commit 4246269

Please sign in to comment.