[Bug target/66337] __alignof__(s.d) incorrect for a double member with -malign-power

dje at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Feb 19 13:33:00 GMT 2016


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66337

David Edelsohn <dje at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Target|powerpc*-*-*-*              |powerpc*-*-*

--- Comment #7 from David Edelsohn <dje at gcc dot gnu.org> ---
I agree that changing the alignment to make the __alignof__ output happy is
wrong.

The "bug" is __alignof__ output on XLC and GCC are different, despite the
actual alignment of the structure and member.

The ADJUST_FIELD_ALIGN computation is correct and I don't believe that GCC
structure layout provides control to describe the alignment of the first member
different than other members of a structure.


More information about the Gcc-bugs mailing list