OSDN Git Service

* gcc.c-torture/execute/20040331-1.c: Don't use too wide a
authorkazu <kazu@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 30 Apr 2004 15:30:55 +0000 (15:30 +0000)
committerkazu <kazu@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 30 Apr 2004 15:30:55 +0000 (15:30 +0000)
bit-field on 16-bit targets.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@81343 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/execute/20040331-1.c

index c0b55a7..5cc6e2e 100644 (file)
@@ -1,5 +1,10 @@
 2004-04-30  Kazu Hirata  <kazu@cs.umass.edu>
 
+       * gcc.c-torture/execute/20040331-1.c: Don't use too wide a
+       bit-field on 16-bit targets.
+
+2004-04-30  Kazu Hirata  <kazu@cs.umass.edu>
+
        * gcc.c-torture/execute/20040409-2.c: Fix constants used on
        16-bit targets.
 
index 67b3e3a..2e8f9e8 100644 (file)
@@ -5,8 +5,16 @@ extern void exit (int);
 int
 main (void)
 {
+#if __INT_MAX__ >= 2147483647
   struct { int count: 31; } s = { 0 };
   while (s.count--)
     abort ();
+#elif __INT_MAX__ >= 32767
+  struct { int count: 15; } s = { 0 };
+  while (s.count--)
+    abort ();
+#else
+  /* Don't bother because __INT_MAX__ is too small.  */
+#endif
   exit (0);
 }