Re: BUG #18610: llvm error: __aarch64_swp4_acq_rel which could not be resolved
Thomas Munro <thomas.munro@gmail.com>
From: Thomas Munro <thomas.munro@gmail.com>
To: a.kozhemyakin@postgrespro.ru, pgsql-bugs@lists.postgresql.org
Date: 2024-09-11T09:55:45Z
Lists: pgsql-bugs
On Wed, Sep 11, 2024 at 7:58 PM PG Bug reporting form <noreply@postgresql.org> wrote: > FATAL: fatal llvm error: Program used external function > '__aarch64_swp4_acq_rel' which could not be resolved! Hmm, I think it is inlining spinlock code from pg_last_wal_receive_lsn()'s call to GetWalRcvFlushRecPtr(), and then failing to find fallbacks for pre-ARMv8.1 systems that didn't have the LSE atomic instructions. I wonder if there could be some mismatch in the default -march for parts of your toolchain, so that it doesn't link the library that has that stuff, but then the clang that built walreceiverfuncs.bc expects it to be found. I wonder if it goes away if you add "-mno-outline-atomics" or "-march=armv8.1-a" or "-march=armv8-a+lse" to BITCODE_CXXFLAGS (not saying that's a fix, just trying to understand what's happening...). Assuming you're using GCC, maybe "gcc -Q --help=target | grep march" could show what Ubuntu 24 has set as the baseline, and "clang -### -c -x c /dev/null" might show what clang is selecting... just ideas, I'm not sure, I don't have such a system, I just noticed a few distros cranking up the baseline instruction sets recently...
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
jit: Use -mno-outline-atomics for bitcode on ARM.
- 8aefd8b6f661 13.19 landed
- 7ca388fd0dec 14.16 landed
- 78c09bd9f94e 18.0 landed
- 8a9a515188c8 17.3 landed
- 6de14dbb3629 16.7 landed
- 15ab513fed04 15.11 landed