Re: Fix misaligned access of ItemPointerData on ARM

From: Piotr Stefaniak <postgres(at)piotr-stefaniak(dot)me>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Fix misaligned access of ItemPointerData on ARM
Date: 2015-05-21 21:06:40
Message-ID: BLU436-SMTP2125686ED51F61A8B24E1FF2C10@phx.gbl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 05/21/2015 10:08 PM, Tom Lane wrote:
> It's not clear to me whether all compilers that accept "packed" also
> accept "aligned", but there are enough ARM machines in the buildfarm
> that we could hope that we'll find out if this isn't portable.

I think src/include/c.h:614 onward, in its current state, guarantees that?

/* GCC, Sunpro and XLC support aligned, packed and noreturn */
#if defined(__GNUC__) || defined(__SUNPRO_C) || defined(__IBMC__)
#define pg_attribute_aligned(a) __attribute__((aligned(a)))
#define pg_attribute_noreturn() __attribute__((noreturn))
#define pg_attribute_packed() __attribute__((packed))
#define HAVE_PG_ATTRIBUTE_NORETURN 1
#else

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2015-05-21 21:12:29 Re: Fix misaligned access of ItemPointerData on ARM
Previous Message Geoff Winkless 2015-05-21 21:03:26 Re: INSERT ... ON CONFLICT DO UPDATE with _any_ constraint