public inbox for [email protected]  
help / color / mirror / Atom feed
From: Andres Freund <[email protected]>
To: Noah Misch <[email protected]>
Cc: Thomas Munro <[email protected]>
Cc: Heikki Linnakangas <[email protected]>
Cc: Peter Smith <[email protected]>
Cc: Robert Haas <[email protected]>
Cc: vignesh C <[email protected]>
Cc: pgsql-hackers <[email protected]>
Cc: Melanie Plageman <[email protected]>
Subject: Re: Relation bulk write facility
Date: Sat, 24 Feb 2024 13:29:36 -0800
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
	<[email protected]>
	<CALDaNm0WYTR4mnvb8nRCWBinFw1kP9x0aSqmdswHj_Nr50YQug@mail.gmail.com>
	<[email protected]>
	<CAHut+Pt3WatNznD8q4wmm1GSR7vAHLNBmHERAmguH9N9LCBx1Q@mail.gmail.com>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<CA+hUKGKtVazR0yEDxOrZYAmeaVbvQxNXSb6K8BDYOtuRVnCMDQ@mail.gmail.com>
	<[email protected]>

Hi,

On 2024-02-24 11:50:24 -0800, Noah Misch wrote:
> > We see this happen with both xlc and gcc (new enough to know how to do
> > this).  One idea would be that the AIX *linker* is unable to align it,
> > as that is the common tool-chain component here (and unlike stack and
> > heap objects, this scope is the linker's job).  There is a
> > pre-existing example of a zero-buffer that is at file scope like that:
> > pg_prewarm.c.  Perhaps it doesn't get tested?
> >
> > Hmm.
>
> GCC docs do say "For some linkers, the maximum supported alignment may be very
> very small.", but AIX "man LD" says "data sections are aligned on a boundary
> so as to satisfy the alignment of all CSECTs in the sections".  It also has -H
> and -K flags to force some particular higher alignment.

Some xlc manual [1] states that

  n must be a positive power of 2, or NIL. NIL can be specified as either
  __attribute__((aligned())) or __attribute__((aligned)); this is the same as
  specifying the maximum system alignment (16 bytes on all UNIX platforms).

Which does seems to suggest that this is a platform restriction.


Let's just drop AIX. This isn't the only alignment issue we've found and the
solution for those isn't so much a fix as forcing everyone to carefully only
look into one direction and not notice the cliffs to either side.

Greetings,

Andres Freund

[1] https://www.ibm.com/docs/en/SSGH2K_13.1.2/com.ibm.compilers.aix.doc/proguide.pdf






view thread (34+ messages)  latest in thread

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 using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: Relation bulk write facility
  In-Reply-To: <[email protected]>

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

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