[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2008-02-14 Thread alexandre dot nunes at gmail dot com
--- Comment #10 from alexandre dot nunes at gmail dot com 2008-02-14 23:15 --- (In reply to comment #9) > We can't change the current behavior/ABI obviously. But the request for > better > documentation is correct. > Would it be feasibly to have a non-fatal testcase for this, so tha

[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2008-02-14 Thread rguenth at gcc dot gnu dot org
--- Comment #9 from rguenth at gcc dot gnu dot org 2008-02-14 23:04 --- We can't change the current behavior/ABI obviously. But the request for better documentation is correct. -- rguenth at gcc dot gnu dot org changed: What|Removed |Added ---

[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2008-02-14 Thread alexandre dot nunes at gmail dot com
--- Comment #8 from alexandre dot nunes at gmail dot com 2008-02-14 22:06 --- (In reply to comment #7) > Yes, so for packed structs (which are a GCCism), GCC sets the rule. Better > documentation is certainly appreciated, but - what is the bug here? Did > the behavior change (I think

[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2008-02-14 Thread rguenth at gcc dot gnu dot org
--- Comment #7 from rguenth at gcc dot gnu dot org 2008-02-14 21:33 --- Yes, so for packed structs (which are a GCCism), GCC sets the rule. Better documentation is certainly appreciated, but - what is the bug here? Did the behavior change (I think it did for some 3.x releases) recently

[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2007-11-02 Thread alexandre dot nunes at gmail dot com
--- Comment #6 from alexandre dot nunes at gmail dot com 2007-11-02 16:58 --- >From the gcc internals (http://gcc.gnu.org/onlinedocs/gccint/Storage-Layout.html): — Target Hook: bool TARGET_MS_BITFIELD_LAYOUT_P (tree record_type) This target hook returns true if bit-fields in the g

[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2007-10-20 Thread alexandre dot nunes at gmail dot com
--- Comment #5 from alexandre dot nunes at gmail dot com 2007-10-20 13:35 --- (In reply to comment #4) > (In reply to comment #2) > > The standard puts all the burden on the implementation (See 6.7.2.1/10). > > The GCC manual in turn says the behavior is specified by the ABI (4.9 > > St

[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2007-10-20 Thread alexandre dot nunes at gmail dot com
--- Comment #4 from alexandre dot nunes at gmail dot com 2007-10-20 12:55 --- (In reply to comment #2) > The standard puts all the burden on the implementation (See 6.7.2.1/10). > The GCC manual in turn says the behavior is specified by the ABI (4.9 > Structures, unions, enumerations, a

[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2007-10-20 Thread alexandre dot nunes at gmail dot com
--- Comment #3 from alexandre dot nunes at gmail dot com 2007-10-20 12:20 --- (In reply to comment #2) > The standard puts all the burden on the implementation (See 6.7.2.1/10). > The GCC manual in turn says the behavior is specified by the ABI (4.9 > Structures, unions, enumerations, a

[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2007-10-20 Thread rguenth at gcc dot gnu dot org
--- Comment #2 from rguenth at gcc dot gnu dot org 2007-10-20 09:47 --- The standard puts all the burden on the implementation (See 6.7.2.1/10). The GCC manual in turn says the behavior is specified by the ABI (4.9 Structures, unions, enumerations, and bit-fields), which would be the sys

[Bug c/33823] bitfields on packed struct aligns by a few bits if the types differ

2007-10-19 Thread alexandre dot nunes at gmail dot com
--- Comment #1 from alexandre dot nunes at gmail dot com 2007-10-20 01:49 --- Created an attachment (id=14374) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14374&action=view) A complete testcase. I compiled with gcc -ggdb3 file.c -o file, no optimization flags. -- http://gc