On Wed, 11 Apr 2018, Jason Merrill wrote:

> On Tue, Apr 10, 2018 at 1:12 PM, Jason Merrill <ja...@redhat.com> wrote:
> > But really this is beside the point: the x86 ABI says that the
> > alignment of double is 4, so alignof(double) should be 4 regardless of
> > what GCC wants to do internally.  And I think the same is true of
> > __alignof__.
> 
> Particularly since the description of __alignof__ has been clarified:
> 
> "Some machines never actually require alignment; they allow reference
> to any data type even at an odd address.  For these machines,
> '__alignof__' reports the smallest alignment that GCC gives the data
> type, usually as mandated by the target ABI."

That text seems inaccurate in the x86 double / long long case; it should 
reflect the preferred alignment of the type for a standalone object.

-- 
Joseph S. Myers
jos...@codesourcery.com

Reply via email to