ChangeLog gcc/
authorKai Tietz <ktietz@redhat.com>
Tue, 12 Apr 2011 18:52:41 +0000 (20:52 +0200)
committerKai Tietz <ktietz@gcc.gnu.org>
Tue, 12 Apr 2011 18:52:41 +0000 (20:52 +0200)
2011-04-12  Kai Tietz  <ktietz@redhat.com>

* config/i386/mingw32.h (TARGET_SUBTARGET_DEFAULT): Add
MASK_MS_BITFIELD_LAYOUT bit.

ChangeLog gcc/testsuite

2011-04-12  Kai Tietz  <ktietz@redhat.com>

* g++.dg/ext/bitfield2.C: Add for i?86/x86_64-*-mingw*
targets the additional -mno-ms-bitfields and
-Wno-packed-bitfield-compat options.
* g++.dg/ext/bitfield3.C: Likewise.
* g++.dg/ext/bitfield4.C: Likewise.
* g++.dg/ext/bitfield5.C: Likewise.
* gcc.dg/bitfld-15.c: Likewise.
* gcc.dg/bitfld-16.c: Likewise.
* gcc.dg/bitfld-17.c: Likewise.
* gcc.dg/bitfld-18.c: Likewise.

From-SVN: r172336

gcc/ChangeLog
gcc/config/i386/mingw32.h
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/ext/bitfield2.C
gcc/testsuite/g++.dg/ext/bitfield3.C
gcc/testsuite/g++.dg/ext/bitfield4.C
gcc/testsuite/g++.dg/ext/bitfield5.C
gcc/testsuite/gcc.dg/bitfld-15.c
gcc/testsuite/gcc.dg/bitfld-16.c
gcc/testsuite/gcc.dg/bitfld-17.c
gcc/testsuite/gcc.dg/bitfld-18.c

index 96f542caea66e3d78461e5a61fe3816ba38d33b1..94d54ac74d5b4396b27fed069309c55313bd4042 100644 (file)
@@ -1,3 +1,8 @@
+2011-04-12  Kai Tietz  <ktietz@redhat.com>
+
+       * config/i386/mingw32.h (TARGET_SUBTARGET_DEFAULT): Add
+       MASK_MS_BITFIELD_LAYOUT bit.
+
 2011-04-12  Jakub Jelinek  <jakub@redhat.com>
 
        * combine.c (update_cfg_for_uncondjump): Instead of testing at_end
index fa55ce421cb38e1cb1cadf0293ed28fbefffe0d6..3c8eee6143a2e6f5fa189e440fe78ef52f2df3e6 100644 (file)
@@ -22,6 +22,17 @@ along with GCC; see the file COPYING3.  If not see
 #undef DEFAULT_ABI
 #define DEFAULT_ABI MS_ABI
 
+/* 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.
+   Additionally we enable MS_BITFIELD_LAYOUT by default.  */
+
+#undef TARGET_SUBTARGET_DEFAULT
+#define TARGET_SUBTARGET_DEFAULT \
+       (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS \
+        | MASK_STACK_PROBE | MASK_ALIGN_DOUBLE \
+        | MASK_MS_BITFIELD_LAYOUT)
+
 /* See i386/crtdll.h for an alternative definition. _INTEGRAL_MAX_BITS
    is for compatibility with native compiler.  */
 #define EXTRA_OS_CPP_BUILTINS()                                        \
index b3fe075f0456ab3da27b4a26c061742477340afb..61ff1c6971d9ec5d18c51aa71107493be6016b4b 100644 (file)
@@ -1,3 +1,16 @@
+2011-04-12  Kai Tietz  <ktietz@redhat.com>
+
+       * g++.dg/ext/bitfield2.C: Add for i?86/x86_64-*-mingw*
+       targets the additional -mno-ms-bitfields and
+       -Wno-packed-bitfield-compat options.
+       * g++.dg/ext/bitfield3.C: Likewise.
+       * g++.dg/ext/bitfield4.C: Likewise.
+       * g++.dg/ext/bitfield5.C: Likewise.
+       * gcc.dg/bitfld-15.c: Likewise.
+       * gcc.dg/bitfld-16.c: Likewise.
+       * gcc.dg/bitfld-17.c: Likewise.
+       * gcc.dg/bitfld-18.c: Likewise.
+
 2011-04-12  Richard Sandiford  <richard.sandiford@linaro.org>
 
        * gcc.target/arm/neon-vld3-1.c: New test.
index 753492ce9949f09ffa968c2334dcda356dc89b62..c288cec7c3307e8017ab57d8bf15cf579a4a40f0 100644 (file)
@@ -1,7 +1,7 @@
 /* { dg-do compile } */
 /* Remove pedantic.  Allow the GCC extension to use char for bitfields.  */
 /* { dg-options "" } */
-/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target { i?86-*-netware i?86-*-mingw* x86_64-*-mingw* } } } */
 
 struct t /* { dg-message "note: offset of packed bit-field 't::b' has changed in GCC 4.4" "" { target pcc_bitfield_type_matters } } */
 {
index 0a89bdab1ff06e620ecca528d9221d39ce95233e..f9fb78cceeeb37f49fd6f89fc1c80728e2dc2642 100644 (file)
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-Wno-packed-bitfield-compat" } */
-/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target { i?86-*-netware i?86-*-mingw* x86_64-*-mingw* } } } */
 
 struct t
 {
index 7bf85533130b98e1b0cdc64fd685b768330e6a10..8562686d6eb99cdec59e95d8235e25b3b4e5298f 100644 (file)
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "" } */
-/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target { i?86-*-netware i?86-*-mingw* x86_64-*-mingw* } } } */
 
 struct t /* { dg-message "note: offset of packed bit-field 't::b' has changed in GCC 4.4" "" { target pcc_bitfield_type_matters } } */
 {
index cb24c65d723b86c65fa54644a27b7b9eeb149056..1d862d769750ce252fa87f95908dcf1f199b6126 100644 (file)
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-Wno-packed-bitfield-compat" } */
-/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target { i?86-*-netware i?86-*-mingw* x86_64-*-mingw* } } } */
 
 struct t
 {
index 44d53b34ae2a0d050dab1642797e8a0b8f8385d4..03f43f2de8c30d587330554f3464a657630703d7 100644 (file)
@@ -2,6 +2,7 @@
 /* Remove pedantic.  Allow the GCC extension to use char for bitfields.  */
 /* { dg-options "" } */
 /* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
+/* { dg-options "-mno-ms-bitfields -Wno-packed-bitfield-compat" { target { i?86-*-mingw* x86_64-*-mingw* } } } */
 
 struct t
 {
index 0a89bdab1ff06e620ecca528d9221d39ce95233e..5ed30f7439280f72fb13c4e34baf298a653515bb 100644 (file)
@@ -1,6 +1,7 @@
 /* { dg-do compile } */
 /* { dg-options "-Wno-packed-bitfield-compat" } */
 /* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target { i?86-*-mingw* x86_64-*-mingw* } } } */
 
 struct t
 {
index 80099c6c9a2a5a9c657851c6e2936916e8cf20c7..9512f5fdf2afe698912f50a7a6aa88f4156db421 100644 (file)
@@ -1,6 +1,7 @@
 /* { dg-do compile } */
 /* { dg-options "" } */
 /* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
+/* { dg-options "-mno-ms-bitfields -Wno-packed-bitfield-compat" { target { i?86-*-mingw* x86_64-*-mingw* } } } */
 
 struct t
 {
index cb24c65d723b86c65fa54644a27b7b9eeb149056..067d9ae3851b2912d2deee4bd76be067be9b4a63 100644 (file)
@@ -1,6 +1,7 @@
 /* { dg-do compile } */
 /* { dg-options "-Wno-packed-bitfield-compat" } */
 /* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
+/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target { i?86-*-mingw* x86_64-*-mingw* } } } */
 
 struct t
 {