OBS-URL: https://build.opensuse.org/package/show/server:database:postgresql/postgresql13?expand=0&rev=37
This commit is contained in:
parent
aa996e2b71
commit
c1e38579a0
@ -12,15 +12,12 @@ causes the JIT to fail at runtime.
|
|||||||
src/backend/jit/llvm/llvmjit.c | 46 ++++++++++++++++++++++++++++++++--
|
src/backend/jit/llvm/llvmjit.c | 46 ++++++++++++++++++++++++++++++++--
|
||||||
1 file changed, 44 insertions(+), 2 deletions(-)
|
1 file changed, 44 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
diff --git a/src/backend/jit/llvm/llvmjit.c b/src/backend/jit/llvm/llvmjit.c
|
--- src/backend/jit/llvm/llvmjit.c.orig
|
||||||
index 98a27f08bf..05b6438ba8 100644
|
+++ src/backend/jit/llvm/llvmjit.c
|
||||||
--- a/src/backend/jit/llvm/llvmjit.c
|
@@ -736,6 +736,35 @@ llvm_compile_module(LLVMJitContext *cont
|
||||||
+++ b/src/backend/jit/llvm/llvmjit.c
|
|
||||||
@@ -776,6 +776,35 @@ llvm_compile_module(LLVMJitContext *context)
|
|
||||||
errhidecontext(true)));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
+/*
|
/*
|
||||||
+ * For the systemz target, LLVM uses a different datalayout for z13 and newer
|
+ * For the systemz target, LLVM uses a different datalayout for z13 and newer
|
||||||
+ * CPUs than it does for older CPUs. This can cause a mismatch in datalayouts
|
+ * CPUs than it does for older CPUs. This can cause a mismatch in datalayouts
|
||||||
+ * in the case where the llvm_types_module is compiled with a pre-z13 CPU
|
+ * in the case where the llvm_types_module is compiled with a pre-z13 CPU
|
||||||
@ -49,10 +46,11 @@ index 98a27f08bf..05b6438ba8 100644
|
|||||||
+ return ret;
|
+ return ret;
|
||||||
+}
|
+}
|
||||||
+
|
+
|
||||||
/*
|
+/*
|
||||||
* Per session initialization.
|
* Per session initialization.
|
||||||
*/
|
*/
|
||||||
@@ -785,6 +814,7 @@ llvm_session_initialize(void)
|
static void
|
||||||
|
@@ -744,6 +773,7 @@ llvm_session_initialize(void)
|
||||||
MemoryContext oldcontext;
|
MemoryContext oldcontext;
|
||||||
char *error = NULL;
|
char *error = NULL;
|
||||||
char *cpu = NULL;
|
char *cpu = NULL;
|
||||||
@ -60,7 +58,7 @@ index 98a27f08bf..05b6438ba8 100644
|
|||||||
char *features = NULL;
|
char *features = NULL;
|
||||||
LLVMTargetMachineRef opt0_tm;
|
LLVMTargetMachineRef opt0_tm;
|
||||||
LLVMTargetMachineRef opt3_tm;
|
LLVMTargetMachineRef opt3_tm;
|
||||||
@@ -816,10 +846,17 @@ llvm_session_initialize(void)
|
@@ -775,10 +805,17 @@ llvm_session_initialize(void)
|
||||||
* features not all CPUs have (weird, huh).
|
* features not all CPUs have (weird, huh).
|
||||||
*/
|
*/
|
||||||
cpu = LLVMGetHostCPUName();
|
cpu = LLVMGetHostCPUName();
|
||||||
@ -79,7 +77,7 @@ index 98a27f08bf..05b6438ba8 100644
|
|||||||
opt0_tm =
|
opt0_tm =
|
||||||
LLVMCreateTargetMachine(llvm_targetref, llvm_triple, cpu, features,
|
LLVMCreateTargetMachine(llvm_targetref, llvm_triple, cpu, features,
|
||||||
LLVMCodeGenLevelNone,
|
LLVMCodeGenLevelNone,
|
||||||
@@ -833,8 +870,13 @@ llvm_session_initialize(void)
|
@@ -792,8 +829,13 @@ llvm_session_initialize(void)
|
||||||
|
|
||||||
LLVMDisposeMessage(cpu);
|
LLVMDisposeMessage(cpu);
|
||||||
cpu = NULL;
|
cpu = NULL;
|
||||||
@ -94,6 +92,3 @@ index 98a27f08bf..05b6438ba8 100644
|
|||||||
|
|
||||||
/* force symbols in main binary to be loaded */
|
/* force symbols in main binary to be loaded */
|
||||||
LLVMLoadLibraryPermanently(NULL);
|
LLVMLoadLibraryPermanently(NULL);
|
||||||
--
|
|
||||||
2.27.0
|
|
||||||
|
|
||||||
|
@ -457,7 +457,7 @@ touch -r configure tmp
|
|||||||
%patch9
|
%patch9
|
||||||
%if %{with llvm}
|
%if %{with llvm}
|
||||||
%patch10
|
%patch10
|
||||||
%patch11 -p1
|
%patch11
|
||||||
%endif
|
%endif
|
||||||
touch -r tmp configure
|
touch -r tmp configure
|
||||||
rm tmp
|
rm tmp
|
||||||
|
Loading…
Reference in New Issue
Block a user