Alexander Korotkov <a.korot...@postgrespro.ru> writes: >> It seems that on this platform definition of atomics should be provided by >> fallback.h. But it doesn't because I already defined >> PG_HAVE_ATOMIC_U32_SUPPORT >> in arch-ppc.h. I think in this case we shouldn't provide ppc-specific >> implementation of pg_atomic_fetch_mask_add_u32(). However, I don't know >> how to do this assuming arch-ppc.h is included before compiler-specific >> headers. Thus, in arch-ppc.h we don't know yet if we would find >> implementation of atomics for this platform. One possible solution is to >> provide assembly implementation for all atomics in arch-ppc.h.
> BTW, implementation for all atomics in arch-ppc.h would be too invasive and > shouldn't be considered for v10. > However, I made following workaround: declare pg_atomic_uint32 and > pg_atomic_fetch_mask_add_u32_impl() only when we know that generic-gcc.h > would declare gcc-based atomics. I don't have a well-informed opinion on whether this is a reasonable thing to do, but I imagine Andres does. > Could you, please, check it on Apple PPC? It does compile and pass "make check" on prairiedog. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers