On Fri, Sep 1, 2023 at 6:13 AM Alexander Lakhin <exclus...@gmail.com> wrote: > (Placing "pg_compiler_barrier();" just after "waiting = true;" fixed the > issue for us.)
Maybe it'd be worth trying something stronger, like pg_memory_barrier(). A compiler barrier doesn't prevent the CPU from reordering loads and stores as it goes, and ARM64 has weak memory ordering. -- Robert Haas EDB: http://www.enterprisedb.com