This is the mail archive of the cygwin-developers@sourceware.cygnus.com
mailing list for the Cygwin project. See the Cygwin
home page for more information.
Re: Patch, Version 4: Problem solved
- To: anorland@hem2.passagen.se
- Subject: Re: Patch, Version 4: Problem solved
- From: DJ Delorie <dj@delorie.com>
- Date: Tue, 4 May 1999 13:45:58 -0400
- CC: cygwin-developers@sourceware.cygnus.com, corinna.vinschen@cityweb.de, cgf@cygnus.com
- References: <372F2F7F.2DDE07F3@hem2.passagen.se>
The alignment of A changes from 4 bytes (sizeof(int)) to 8 bytes
(sizeof(double)), so the alignment of B (which contains A) must also
change from 4 to 8. The size of B is increased to a multiple of the
alignment so that each element of an array of such objects is properly
aligned. IMHO, this is correct and expected behavior.
If MS wants them "less aligned" you'll have to use gcc's alignment
directives to reduce the alignment of that double to 4.