http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52238
Bug #: 52238 Summary: -mms-bitfields: __attribute__ ((aligned (n))) ignored for struct members Classification: Unclassified Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: c AssignedTo: unassig...@gcc.gnu.org ReportedBy: michael.kosty...@gmail.com The following test case % cat > test.c << __EOF && gcc -mms-bitfields test.c && { ./a.out ; echo $? ; } struct { char a; char b __attribute__ ((aligned (16))); } s; int main() { return (__PTRDIFF_TYPE__)&s.b & 15; } __EOF returns 1, since s.b is not 16-byte aligned (with -mno-ms-bitfields it returns 0, as expected). The test passes with 4.1.2, but fails with 4.2.1 and above.