This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/50521] -fstrict-volatile-bitfields is not strict


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50521

--- Comment #9 from Henrik NordstrÃm <henrik at henriknordstrom dot net> 2011-10-28 07:32:48 UTC ---
C standard does not define any of this It's all implementation and platform ABI
dependent. 


The C standard does define not storage size of a bit-field other than that it's
sufficiently large, or bit-fields of other types than _Bool and int
(+qualifiers), or if bits outside the specific bit-field is accessed as side
effect when operating on a bit-field.


For example the ARM ABI defines volatile bitfield memory access in full detail
as being equal to the base type of the bitfield, and I see now that it actually
requires a double load in the mentioned test case. See
http://infocenter.arm.com/help/topic/com.arm.doc.ihi0042d/IHI0042D_aapcs.pdf
section 7.1.7.5.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]