]> granicus.if.org Git - postgresql/commitdiff
LLVMJIT: Fix LLVM build for LLVM > 7.
authorAndres Freund <andres@anarazel.de>
Mon, 23 Jul 2018 04:05:06 +0000 (21:05 -0700)
committerAndres Freund <andres@anarazel.de>
Mon, 23 Jul 2018 04:13:02 +0000 (21:13 -0700)
The location of LLVMAddPromoteMemoryToRegisterPass moved.

Author: Andres Freund
Backpatch: 11, where LLVM based JIT support was added.

src/backend/jit/llvm/llvmjit.c

index 5d0cdab1fc68991f43e26dce4e97d567d48bb81a..955c96671399f6d2f5b975946de0a6c772e4f87b 100644 (file)
@@ -34,6 +34,9 @@
 #include <llvm-c/Transforms/IPO.h>
 #include <llvm-c/Transforms/PassManagerBuilder.h>
 #include <llvm-c/Transforms/Scalar.h>
+#if LLVM_VERSION_MAJOR > 6
+#include <llvm-c/Transforms/Utils.h>
+#endif
 
 
 /* Handle of a module emitted via ORC JIT */