Re: [patch] Support LLVM 7
Andres Freund <andres@anarazel.de>
From: Andres Freund <andres@anarazel.de>
To: Christoph Berg <myon@debian.org>, PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Date: 2018-09-20T17:32:38Z
Lists: pgsql-hackers
Hi, On 2018-09-20 10:10:44 +0200, Christoph Berg wrote: > In the meantime, there's a third architecture where llvm itself > compiled, but explodes with PG11 - x32: > > SELECT '' AS tf_12, BOOLTBL1.*, BOOLTBL2.* > FROM BOOLTBL1, BOOLTBL2 > WHERE BOOLTBL2.f1 <> BOOLTBL1.f1; > ! FATAL: fatal llvm error: Cannot select: 0x57a7ae60: ch,glue = X86ISD::CALL 0x57a7add0, 0x57a7af38, Register:i32 $edi, RegisterMask:Untyped, 0x57a7add0:1 > ! 0x57a7af38: i32 = X86ISD::Wrapper TargetGlobalAddress:i32<void (%struct.TupleTableSlot*)* @deform_0_1> 0 > ! 0x57a7aef0: i32 = TargetGlobalAddress<void (%struct.TupleTableSlot*)* @deform_0_1> 0 > ! 0x57a7ad88: i32 = Register $edi > ! 0x57a7ae18: Untyped = RegisterMask > ! 0x57a7add0: ch,glue = CopyToReg 0x57a7ad40, Register:i32 $edi, 0x57a7acb0 > ! 0x57a7ad88: i32 = Register $edi > ! 0x57a7acb0: i32,ch = CopyFromReg 0x57a367ac, Register:i32 %27 > ! 0x57a7ac68: i32 = Register %27 > ! In function: evalexpr_0_0 > ! server closed the connection unexpectedly > ! This probably means the server terminated abnormally > ! before or while processing the request. > ! connection to server was lost > > https://buildd.debian.org/status/fetch.php?pkg=postgresql-11&arch=x32&ver=11~beta3-2&stamp=1537286634&raw=0 That's pretty clearly an LLVM bug. Could you enable jit_dump_bitcode and send the bitcode files (I assume there should be something like <pid>.<generation>.bc and the same with <prefix>.optimized.bc) from the data directory? Not that I think x32 is a particularly popular database platform, but LLVM clearly needs to be fixed independent of PG... Greetings, Andres Freund
Commits
-
Detect LLVM 7 without specifying binaries explicitly.
- 99ba795d982e 11.0 landed
- 240d40db88ec 12.0 landed