This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[Patch]: Align doubles on 64 bit boundaries as default for mingw32 and cygwin
- From: Danny Smith <danny_r_smith_2001 at yahoo dot co dot nz>
- To: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Cc: Christopher Faylor <cgf at redhat dot com>
- Date: Sun, 16 Feb 2003 14:38:34 +1100 (EST)
- Subject: [Patch]: Align doubles on 64 bit boundaries as default for mingw32 and cygwin
Hello
Native compiler, by default, aligns doubles in structures to 64 bit
boundaries. Defining BIGGEST_FIELD_ALIGNMENT to 64 used to ensure
that cygwin and mingw remained compatible with MSVC objects. Now
that this is controlled by x86_field_alignment, we need to align doubles
on 64 bit boundaries throughout.
This fixes a regression from gcc-3.0
Tested on i386-pc-mingw32 on trunk and 3.3 branch.
Okay for trunk and 3.3 branch?
Danny
2003-02-16 Danny Smith <dannysmith@users.sourceforge.net>
* config/i386/cygwin.h (TARGET_SUBTARGET_DEFAULT): Set
MASK_ALIGN_DOUBLE.
Index: cygwin.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/i386/cygwin.h,v
retrieving revision 1.79
diff -c -3 -p -r1.79 cygwin.h
*** cygwin.h 15 Feb 2003 04:58:21 -0000 1.79
--- cygwin.h 15 Feb 2003 22:12:08 -0000
*************** do { \
*** 307,317 ****
#define CHECK_STACK_LIMIT 4000
/* By default, target has a 80387, uses IEEE compatible arithmetic,
! and returns float values in the 387 and needs stack probes */
! #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_SUBTARGET_DEFAULT \
! (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_STACK_PROBE)
/* This is how to output an assembler line
that says to advance the location counter
--- 307,320 ----
#define CHECK_STACK_LIMIT 4000
/* By default, target has a 80387, uses IEEE compatible arithmetic,
! returns float values in the 387 and needs stack probes.
! We also align doubles to 64-bits for MSVC default compatibility. */
+ #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_SUBTARGET_DEFAULT \
! (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_STACK_PROBE \
! | MASK_ALIGN_DOUBLE)
!
/* This is how to output an assembler line
that says to advance the location counter
http://mobile.yahoo.com.au - Yahoo! Mobile
- Exchange IMs with Messenger friends on your Telstra or Vodafone mobile phone.