Fix g++.dg/abi/empty6.C failure for BIGGEST_ALIGNMENT <= 32 targets
Mark Mitchell
mark@codesourcery.com
Tue Jun 3 21:27:00 GMT 2003
On Tue, 2003-06-03 at 10:45, Joern Rennecke wrote:
>
> --
> --------------------------
> SuperH (UK) Ltd.
> 2410 Aztec West / Almondsbury / BRISTOL / BS32 4QX
> T:+44 1454 465658
> ----
>
> SH1..SH4 has a BIGGEST_ALIGNEMNT of 32 bit, so if a class definition
> does not demand a larger alignment, an offset of 32 bit
> gets split into a DECL_FIELD_OFFSET of 4 bytes
> and a DECL_FIELD_BIT_OFFSET of 0 bits.
> Thus, DECL_FIELD_OFFSET and byte_position are the same for field a
> in struct B of g++.dg/abi/empty6.C , so no warning about ABI compliance
> is emitted.
> This can be simply rectified by aligning B to something larger than 32 bit.
>
> 2003-06-03 J"orn Rennecke <joern.rennecke@superh.com>
>
> * g++.dg/abi/empty6.C (B): Request alignment of 8 bytes.
OK -- but put this justification into a comment in the code.
Thanks!
-- Mark
More information about the Gcc-patches
mailing list