pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Noah Misch <noah@leadboat.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: For all ppc compilers, implement pg_atomic_fetch_add_ with inlin
Date: Sat, 14 Sep 2019 10:11:54 -0700
Message-ID: <20190914171154.GA3487808@rfd.leadboat.com> (raw)
In-Reply-To: <7517.1568470247@sss.pgh.pa.us>
References: <E1i8y0J-00076V-LN@gemulon.postgresql.org>
	<7517.1568470247@sss.pgh.pa.us>

On Sat, Sep 14, 2019 at 10:10:47AM -0400, Tom Lane wrote:
> Noah Misch <noah@leadboat.com> writes:
> > For all ppc compilers, implement pg_atomic_fetch_add_ with inline asm.
> 
> prairiedog thinks there's something wrong here --- probably, some global
> enabling #define is missing?

I can reproduce its situation by commenting out the HAVE_GCC_ symbols in
pg_config.h.  This commit did "#define PG_HAVE_ATOMIC_U32_SUPPORT" but defined
only fetch_add, not compare_exchange.  That works with generic-gcc.h, but
fallback.h can't replace just one.  (Rightly so -- fallback.h defines the
pg_atomic_uint32 structure differently.)  I can see these ways to fix this:

1. Add pg_atomic_compare_exchange_u{32,64}_impl to arch-ppc.h
2. Arrange for arch-ppc.h to be a no-op when GCC atomics are unavailable
3. Just revert

(1) seems best.  Since it may be days or weeks before I get to that, I'm
inclined to revert after ~24h of total buildfarm exposure.





view thread (4+ messages)  latest in thread

Message-ID: <20190914171154.GA3487808@rfd.leadboat.com>
Permalink:  ../20190914171154.GA3487808@rfd.leadboat.com/
Also on:    postgresql.org/message-id/20190914171154.GA3487808@rfd.leadboat.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: noah@leadboat.com, tgl@sss.pgh.pa.us
  Subject: Re: pgsql: For all ppc compilers, implement pg_atomic_fetch_add_ with inlin
  In-Reply-To: <20190914171154.GA3487808@rfd.leadboat.com>
  References: <E1i8y0J-00076V-LN@gemulon.postgresql.org> <7517.1568470247@sss.pgh.pa.us> <20190914171154.GA3487808@rfd.leadboat.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox