Re: Do we work with LLVM 12 on s390x? - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Do we work with LLVM 12 on s390x?
Date
Msg-id 20210319190047.7o4bwhbp5dzkqif3@alap3.anarazel.de
Whole thread Raw
In response to Do we work with LLVM 12 on s390x?  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Do we work with LLVM 12 on s390x?
List pgsql-hackers
Hi,

On 2021-03-19 14:03:21 -0400, Tom Lane wrote:
> The Red Hat folk are seeing a problem with that combination:
> 
> https://bugzilla.redhat.com/show_bug.cgi?id=1940964
> 
> which boils down to
> 
> > Build fails with this error:
> > ERROR:  failed to JIT module: Added modules have incompatible data layouts:
E-m:e-i1:8:16-i8:8:16-i64:64-f128:64-a:8:16-n32:64(module) vs
E-m:e-i1:8:16-i8:8:16-i64:64-f128:64-v128:64-a:8:16-n32:64(jit)
 
> 
> (By "build", I imagine the reporter means "regression tests")
> 
> So I was wondering if we'd tested it yet.

Yes, I did test it not too long ago, after Christoph Berg reported
Debian s390x failing with jit. Which made me learn a bunch of s390x
assembler and discover a bug in our code that only rarely happend (iirc
something about booleans that are not exactly 0 or 1 not testing
true)...

https://www.postgresql.org/message-id/20201015222924.yyms42qjloydfvar%40alap3.anarazel.de

I think the error above comes from a "mismatch" between the clang used
to compile bitcode, and the LLVM version linked to. Normally we're
somewhat tolerant of differences between the two, but there was an ABI
change at some point, leading to that error.  IIRC I hit that, but it
vanished as soon as I used a matching libllvm and clang.

Greetings,

Andres Freund



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Replication slot stats misgivings
Next
From: Tom Lane
Date:
Subject: Re: Do we work with LLVM 12 on s390x?