This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/52023] _Alignof (double) yields wrong value on x86
- From: "pinskia at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 27 Jan 2012 21:09:53 +0000
- Subject: [Bug target/52023] _Alignof (double) yields wrong value on x86
- Auto-submitted: auto-generated
- References: <bug-52023-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023
--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> 2012-01-27 21:09:53 UTC ---
One more comment about _Alignof and structures.
Take the following two structures on powerpc-aix (and on powerpc-darwin):
struct
{
double d;
int i;
};
struct
{
int i;
double d;
};
They have two different alignments. The first one is the alignment of double
and the second is alignment of int. This is because is how the ABI documents
alignment works.