[patch]: new returns misaligned pointers

Jason Merrill jason@cygnus.com
Sat Nov 13 01:46:00 GMT 1999

>>>>> Mark Mitchell <mark@codesourcery.com> writes:

>>>>> "Jason" == Jason Merrill <jason@cygnus.com> writes:
>>>>> Richard Henderson <rth@cygnus.com> writes:

 >>> It's up to someone C++-ish to decide if breaking the ABI for
 >>> those defining BIGGEST_ALIGNMENT smaller than `double' is a
 >>> reasonable thing to do.

 Jason> But this change doesn't break the ABI on those targets;
 Jason> double will never have a TYPE_ALIGN larger than

 > I must be a moron.  I'm still confused.

 > Assume that before double was 8-byte aligned, but long double was
 > 16-byte aligned, and so BIGGEST_ALIGNMENT is 128.  Then, doesn't this
 > patch increase the alignment of the cookie to 16 bytes?  And thereby
 > move the first element in the array?  And isn't that an ABI change?

Yes, yes, and yes.  Note that I was talking about targets that define
BIGGEST_ALIGNMENT to something smaller than double.


More information about the Gcc-patches mailing list