This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/52238] -mms-bitfields: __attribute__ ((aligned (n))) ignored for struct members
- From: "michael.kostylev at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 16 Feb 2012 13:26:24 +0000
- Subject: [Bug target/52238] -mms-bitfields: __attribute__ ((aligned (n))) ignored for struct members
- Auto-submitted: auto-generated
- References: <bug-52238-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52238
--- Comment #3 from Michael Kostylev <michael.kostylev at gmail dot com> 2012-02-16 13:26:24 UTC ---
Ok, let's modify the test case - s/char a;/char a:6;/:
struct {
char a:6;
char b __attribute__ ((aligned (16)));
} s;
int main()
{
return (__PTRDIFF_TYPE__)&s.b & 15;
}
The b member is still misaligned, moreover, its offset is equal to 0x11 after
patching.