This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[patch] gcc.dg/compat: use fp values from arrays, not expressions
- From: Janis Johnson <janis187 at us dot ibm dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Mon, 26 Apr 2004 16:55:31 -0700
- Subject: [patch] gcc.dg/compat: use fp values from arrays, not expressions
This patch changes the gcc.dg/compat tests that compare floating point
values to use values from arrays rather than recomputing them each time
they are used. Zack said this should make it easier to hunt down the
causes of test failures.
Tested on powerpc64-unknown-linux-gnu and i686-pc-linux-gnu.
I maintain this test suite, so unless there are suggestions for improving
this patch I'll commit it to mainline in a day or two.
2004-04-26 Janis Johnson <janis187@us.ibm.com>
* gcc.dg/compat/fp-struct-check.h (CHECKS): Compare values from an
array instead of from expressions.
* gcc.dg/compat/fp-struct-init.h (INITS): Same for initializations.
* gcc.dg/compat/fp-struct-test-by-value-x.h (TEST): Fix init calls.
* gcc.dg/compat/fp-struct-test-by-value-y.h (TEST): Fix checks calls.
* gcc.dg/compat/struct-by-value-11_x.c: Define array of values, use
new versions of macros.
* gcc.dg/compat/struct-by-value-11_y.c: Ditto.
* gcc.dg/compat/struct-by-value-12_x.c: Ditto.
* gcc.dg/compat/struct-by-value-12_y.c: Ditto.
* gcc.dg/compat/struct-by-value-13_x.c: Ditto.
* gcc.dg/compat/struct-by-value-13_y.c: Ditto.
* gcc.dg/compat/struct-by-value-14_x.c: Ditto.
* gcc.dg/compat/struct-by-value-14_y.c: Ditto.
* gcc.dg/compat/struct-by-value-15_x.c: Ditto.
* gcc.dg/compat/struct-by-value-15_y.c: Ditto.
* gcc.dg/compat/struct-by-value-16_x.c: Ditto.
* gcc.dg/compat/struct-by-value-16_y.c: Ditto.
* gcc.dg/compat/struct-by-value-17_x.c: Ditto.
* gcc.dg/compat/struct-by-value-17_y.c: Ditto.
* gcc.dg/compat/struct-by-value-18_x.c: Ditto.
* gcc.dg/compat/struct-by-value-18_y.c: Ditto.
* gcc.dg/compat/struct-by-value-5a_x.c: Ditto.
* gcc.dg/compat/struct-by-value-5a_y.c: Ditto.
* gcc.dg/compat/struct-by-value-5b_x.c: Ditto.
* gcc.dg/compat/struct-by-value-5b_y.c: Ditto.
* gcc.dg/compat/struct-by-value-6a_x.c: Ditto.
* gcc.dg/compat/struct-by-value-6a_y.c: Ditto.
* gcc.dg/compat/struct-by-value-6b_x.c: Ditto.
* gcc.dg/compat/struct-by-value-6b_y.c: Ditto.
* gcc.dg/compat/struct-by-value-7a_x.c: Ditto.
* gcc.dg/compat/struct-by-value-7a_y.c: Ditto.
* gcc.dg/compat/struct-by-value-7b_x.c: Ditto.
* gcc.dg/compat/struct-by-value-7b_y.c: Ditto.
Index: testsuite/gcc.dg/compat/fp-struct-check.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/fp-struct-check.h,v
retrieving revision 1.2
diff -u -p -r1.2 fp-struct-check.h
--- testsuite/gcc.dg/compat/fp-struct-check.h 10 Jun 2003 19:08:33 -0000 1.2
+++ testsuite/gcc.dg/compat/fp-struct-check.h 26 Apr 2004 23:39:07 -0000
@@ -1,71 +1,74 @@
/* Function definitions that are used by multiple tests. */
#define CHECKS(NAME,TYPEM) \
-void checkS##NAME##1 (S##NAME##1 x, TYPEM y) \
-{ if (x.a != y) DEBUG_CHECK } \
-void checkS##NAME##2 (S##NAME##2 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 ) DEBUG_CHECK } \
-void checkS##NAME##3 (S##NAME##3 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 ) \
- DEBUG_CHECK } \
-void checkS##NAME##4 (S##NAME##4 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3) \
- DEBUG_CHECK } \
-void checkS##NAME##5 (S##NAME##5 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4) DEBUG_CHECK } \
-void checkS##NAME##6 (S##NAME##6 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5) DEBUG_CHECK } \
-void checkS##NAME##7 (S##NAME##7 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6) \
- DEBUG_CHECK } \
-void checkS##NAME##8 (S##NAME##8 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6 \
- || x.h != y+7) DEBUG_CHECK } \
-void checkS##NAME##9 (S##NAME##9 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6 \
- || x.h != y+7 || x.i != y+8) DEBUG_CHECK } \
-void checkS##NAME##10 (S##NAME##10 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6 \
- || x.h != y+7 || x.i != y+8 || x.j != y+9) \
+void checkS##NAME##1 (S##NAME##1 x, TYPEM *y) \
+{ if (x.a != y[0]) DEBUG_CHECK } \
+void checkS##NAME##2 (S##NAME##2 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] ) \
+ DEBUG_CHECK } \
+void checkS##NAME##3 (S##NAME##3 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] ) \
+ DEBUG_CHECK } \
+void checkS##NAME##4 (S##NAME##4 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3]) \
+ DEBUG_CHECK } \
+void checkS##NAME##5 (S##NAME##5 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4]) \
+ DEBUG_CHECK } \
+void checkS##NAME##6 (S##NAME##6 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5]) \
+ DEBUG_CHECK } \
+void checkS##NAME##7 (S##NAME##7 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6]) \
+ DEBUG_CHECK } \
+void checkS##NAME##8 (S##NAME##8 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6] \
+ || x.h != y[7]) DEBUG_CHECK } \
+void checkS##NAME##9 (S##NAME##9 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6] \
+ || x.h != y[7] || x.i != y[8]) DEBUG_CHECK } \
+void checkS##NAME##10 (S##NAME##10 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6] \
+ || x.h != y[7] || x.i != y[8] || x.j != y[9]) \
DEBUG_CHECK } \
-void checkS##NAME##11 (S##NAME##11 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6 \
- || x.h != y+7 || x.i != y+8 || x.j != y+9 \
- || x.k != y+10) DEBUG_CHECK } \
-void checkS##NAME##12 (S##NAME##12 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6 \
- || x.h != y+7 || x.i != y+8 || x.j != y+9 \
- || x.k != y+10 || x.l != y+11) DEBUG_CHECK } \
-void checkS##NAME##13 (S##NAME##13 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6 \
- || x.h != y+7 || x.i != y+8 || x.j != y+9 \
- || x.k != y+10 || x.l != y+11 || x.m != y+12) \
- DEBUG_CHECK } \
-void checkS##NAME##14 (S##NAME##14 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6 \
- || x.h != y+7 || x.i != y+8 || x.j != y+9 \
- || x.k != y+10 || x.l != y+11 || x.m != y+12 \
- || x.n != y+13) DEBUG_CHECK } \
-void checkS##NAME##15 (S##NAME##15 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6 \
- || x.h != y+7 || x.i != y+8 || x.j != y+9 \
- || x.k != y+10 || x.l != y+11 || x.m != y+12 \
- || x.n != y+13 || x.o != y+14) DEBUG_CHECK } \
-void checkS##NAME##16 (S##NAME##16 x, TYPEM y) \
-{ if (x.a != y || x.b != y+1 || x.c != y+2 || x.d != y+3 \
- || x.e != y+4 || x.f != y+5 || x.g != y+6 \
- || x.h != y+7 || x.i != y+8 || x.j != y+9 \
- || x.k != y+10 || x.l != y+11 || x.m != y+12 \
- || x.n != y+13 || x.o != y+14 || x.p != y+15) \
+void checkS##NAME##11 (S##NAME##11 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6] \
+ || x.h != y[7] || x.i != y[8] || x.j != y[9] \
+ || x.k != y[10]) DEBUG_CHECK } \
+void checkS##NAME##12 (S##NAME##12 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6] \
+ || x.h != y[7] || x.i != y[8] || x.j != y[9] \
+ || x.k != y[10] || x.l != y[11]) DEBUG_CHECK } \
+void checkS##NAME##13 (S##NAME##13 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6] \
+ || x.h != y[7] || x.i != y[8] || x.j != y[9] \
+ || x.k != y[10] || x.l != y[11] || x.m != y[12]) \
+ DEBUG_CHECK } \
+void checkS##NAME##14 (S##NAME##14 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6] \
+ || x.h != y[7] || x.i != y[8] || x.j != y[9] \
+ || x.k != y[10] || x.l != y[11] || x.m != y[12] \
+ || x.n != y[13]) DEBUG_CHECK } \
+void checkS##NAME##15 (S##NAME##15 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6] \
+ || x.h != y[7] || x.i != y[8] || x.j != y[9] \
+ || x.k != y[10] || x.l != y[11] || x.m != y[12] \
+ || x.n != y[13] || x.o != y[14]) DEBUG_CHECK } \
+void checkS##NAME##16 (S##NAME##16 x, TYPEM *y) \
+{ if (x.a != y[0] || x.b != y[1] || x.c != y[2] || x.d != y[3] \
+ || x.e != y[4] || x.f != y[5] || x.g != y[6] \
+ || x.h != y[7] || x.i != y[8] || x.j != y[9] \
+ || x.k != y[10] || x.l != y[11] || x.m != y[12] \
+ || x.n != y[13] || x.o != y[14] || x.p != y[15]) \
DEBUG_CHECK }
Index: testsuite/gcc.dg/compat/fp-struct-init.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/fp-struct-init.h,v
retrieving revision 1.1
diff -u -p -r1.1 fp-struct-init.h
--- testsuite/gcc.dg/compat/fp-struct-init.h 20 May 2003 22:15:45 -0000 1.1
+++ testsuite/gcc.dg/compat/fp-struct-init.h 26 Apr 2004 23:39:07 -0000
@@ -1,54 +1,59 @@
/* Function definitions that are used by multiple tests. */
#define INITS(NAME,TYPEM) \
-void initS##NAME##1 (S##NAME##1 *p, TYPEM y) \
-{ p->a = y; } \
-void initS##NAME##2 (S##NAME##2 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; } \
-void initS##NAME##3 (S##NAME##3 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; } \
-void initS##NAME##4 (S##NAME##4 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; } \
-void initS##NAME##5 (S##NAME##5 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; } \
-void initS##NAME##6 (S##NAME##6 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; } \
-void initS##NAME##7 (S##NAME##7 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; } \
-void initS##NAME##8 (S##NAME##8 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; p->h = y+7; } \
-void initS##NAME##9 (S##NAME##9 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; p->h = y+7; p->i = y+8; } \
-void initS##NAME##10 (S##NAME##10 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; p->h = y+7; p->i = y+8; p->j = y+9; } \
-void initS##NAME##11 (S##NAME##11 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; p->h = y+7; p->i = y+8; p->j = y+9; \
- p->k = y+10; } \
-void initS##NAME##12 (S##NAME##12 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; p->h = y+7; p->i = y+8; p->j = y+9; \
- p->k = y+10; p->l = y+11; } \
-void initS##NAME##13 (S##NAME##13 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; p->h = y+7; p->i = y+8; p->j = y+9; \
- p->k = y+10; p->l = y+11; p->m = y+12; } \
-void initS##NAME##14 (S##NAME##14 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; p->h = y+7; p->i = y+8; p->j = y+9; \
- p->k = y+10; p->l = y+11; p->m = y+12; p->n = y+13; } \
-void initS##NAME##15 (S##NAME##15 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; p->h = y+7; p->i = y+8; p->j = y+9; \
- p->k = y+10; p->l = y+11; p->m = y+12; p->n = y+13; \
- p->o = y+14; } \
-void initS##NAME##16 (S##NAME##16 *p, TYPEM y) \
-{ p->a = y; p->b = y+1; p->c = y+2; p->d = y+3; p->e = y+4; \
- p->f = y+5; p->g = y+6; p->h = y+7; p->i = y+8; p->j = y+9; \
- p->k = y+10; p->l = y+11; p->m = y+12; p->n = y+13; \
- p->o = y+14; p->p = y+15; }
+void initS##NAME##1 (S##NAME##1 *p, TYPEM *y) \
+{ p->a = y[0]; } \
+void initS##NAME##2 (S##NAME##2 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; } \
+void initS##NAME##3 (S##NAME##3 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; } \
+void initS##NAME##4 (S##NAME##4 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; } \
+void initS##NAME##5 (S##NAME##5 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; } \
+void initS##NAME##6 (S##NAME##6 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; } \
+void initS##NAME##7 (S##NAME##7 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; } \
+void initS##NAME##8 (S##NAME##8 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; p->h = y[7]; } \
+void initS##NAME##9 (S##NAME##9 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; p->h = y[7]; \
+ p->i = y[8]; } \
+void initS##NAME##10 (S##NAME##10 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; p->h = y[7]; \
+ p->i = y[8]; p->j = y[9]; } \
+void initS##NAME##11 (S##NAME##11 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; p->h = y[7]; \
+ p->i = y[8]; p->j = y[9]; p->k = y[10]; } \
+void initS##NAME##12 (S##NAME##12 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; p->h = y[7]; \
+ p->i = y[8]; p->j = y[9]; p->k = y[10]; p->l = y[11]; } \
+void initS##NAME##13 (S##NAME##13 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; p->h = y[7]; \
+ p->i = y[8]; p->j = y[9]; p->k = y[10]; p->l = y[11]; \
+ p->m = y[12]; } \
+void initS##NAME##14 (S##NAME##14 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; p->h = y[7]; \
+ p->i = y[8]; p->j = y[9]; p->k = y[10]; p->l = y[11]; \
+ p->m = y[12]; p->n = y[13]; } \
+void initS##NAME##15 (S##NAME##15 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; p->h = y[7]; \
+ p->i = y[8]; p->j = y[9]; p->k = y[10]; p->l = y[11]; \
+ p->m = y[12]; p->n = y[13]; p->o = y[14]; } \
+void initS##NAME##16 (S##NAME##16 *p, TYPEM *y) \
+{ p->a = y[0]; p->b = y[1]; p->c = y[2]; p->d = y[3]; \
+ p->e = y[4]; p->f = y[5]; p->g = y[6]; p->h = y[7]; \
+ p->i = y[8]; p->j = y[9]; p->k = y[10]; p->l = y[11]; \
+ p->m = y[12]; p->n = y[13]; p->o = y[14]; p->p = y[15]; }
Index: testsuite/gcc.dg/compat/fp-struct-test-by-value-x.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/fp-struct-test-by-value-x.h,v
retrieving revision 1.2
diff -u -p -r1.2 fp-struct-test-by-value-x.h
--- testsuite/gcc.dg/compat/fp-struct-test-by-value-x.h 10 Jun 2003 19:08:33 -0000 1.2
+++ testsuite/gcc.dg/compat/fp-struct-test-by-value-x.h 26 Apr 2004 23:39:07 -0000
@@ -1,10 +1,10 @@
-#define TEST(TYPE,MTYPE) \
+#define TEST(NAME,TYPE,MTYPE) \
TYPE g1s##TYPE, g2s##TYPE, g3s##TYPE, g4s##TYPE; \
TYPE g5s##TYPE, g6s##TYPE, g7s##TYPE, g8s##TYPE; \
TYPE g9s##TYPE, g10s##TYPE, g11s##TYPE, g12s##TYPE; \
TYPE g13s##TYPE, g14s##TYPE, g15s##TYPE, g16s##TYPE; \
\
-extern void init##TYPE (TYPE *p, MTYPE x); \
+extern void init##TYPE (TYPE *p, MTYPE *x); \
extern void checkg##TYPE (void); \
extern void \
test##TYPE (TYPE s1, TYPE s2, TYPE s3, TYPE s4, \
@@ -28,22 +28,22 @@ testit##TYPE (void) \
{ \
DEBUG_FPUTS (#TYPE); \
DEBUG_FPUTS (" init: "); \
- init##TYPE ( &g1s##TYPE, (MTYPE)1); \
- init##TYPE ( &g2s##TYPE, (MTYPE)2); \
- init##TYPE ( &g3s##TYPE, (MTYPE)3); \
- init##TYPE ( &g4s##TYPE, (MTYPE)4); \
- init##TYPE ( &g5s##TYPE, (MTYPE)5); \
- init##TYPE ( &g6s##TYPE, (MTYPE)6); \
- init##TYPE ( &g7s##TYPE, (MTYPE)7); \
- init##TYPE ( &g8s##TYPE, (MTYPE)8); \
- init##TYPE ( &g9s##TYPE, (MTYPE)9); \
- init##TYPE (&g10s##TYPE, (MTYPE)10); \
- init##TYPE (&g11s##TYPE, (MTYPE)11); \
- init##TYPE (&g12s##TYPE, (MTYPE)12); \
- init##TYPE (&g13s##TYPE, (MTYPE)13); \
- init##TYPE (&g14s##TYPE, (MTYPE)14); \
- init##TYPE (&g15s##TYPE, (MTYPE)15); \
- init##TYPE (&g16s##TYPE, (MTYPE)16); \
+ init##TYPE ( &g1s##TYPE, &NAME##values[1]); \
+ init##TYPE ( &g2s##TYPE, &NAME##values[2]); \
+ init##TYPE ( &g3s##TYPE, &NAME##values[3]); \
+ init##TYPE ( &g4s##TYPE, &NAME##values[4]); \
+ init##TYPE ( &g5s##TYPE, &NAME##values[5]); \
+ init##TYPE ( &g6s##TYPE, &NAME##values[6]); \
+ init##TYPE ( &g7s##TYPE, &NAME##values[7]); \
+ init##TYPE ( &g8s##TYPE, &NAME##values[8]); \
+ init##TYPE ( &g9s##TYPE, &NAME##values[9]); \
+ init##TYPE (&g10s##TYPE, &NAME##values[10]); \
+ init##TYPE (&g11s##TYPE, &NAME##values[11]); \
+ init##TYPE (&g12s##TYPE, &NAME##values[12]); \
+ init##TYPE (&g13s##TYPE, &NAME##values[13]); \
+ init##TYPE (&g14s##TYPE, &NAME##values[14]); \
+ init##TYPE (&g15s##TYPE, &NAME##values[15]); \
+ init##TYPE (&g16s##TYPE, &NAME##values[16]); \
checkg##TYPE (); \
DEBUG_NL; \
DEBUG_FPUTS (#TYPE); \
Index: testsuite/gcc.dg/compat/fp-struct-test-by-value-y.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/fp-struct-test-by-value-y.h,v
retrieving revision 1.2
diff -u -p -r1.2 fp-struct-test-by-value-y.h
--- testsuite/gcc.dg/compat/fp-struct-test-by-value-y.h 10 Jun 2003 19:08:33 -0000 1.2
+++ testsuite/gcc.dg/compat/fp-struct-test-by-value-y.h 26 Apr 2004 23:39:07 -0000
@@ -1,30 +1,31 @@
-#define TEST(TYPE,TYPE2) \
+#define TEST(NAME,TYPE,TYPE2) \
extern TYPE g1s##TYPE, g2s##TYPE, g3s##TYPE, g4s##TYPE; \
extern TYPE g5s##TYPE, g6s##TYPE, g7s##TYPE, g8s##TYPE; \
extern TYPE g9s##TYPE, g10s##TYPE, g11s##TYPE, g12s##TYPE; \
extern TYPE g13s##TYPE, g14s##TYPE, g15s##TYPE, g16s##TYPE; \
\
-extern void check##TYPE (TYPE x, TYPE2 y); \
+extern void check##TYPE (TYPE x, TYPE2 *y); \
+extern TYPE2 NAME##values[]; \
\
void \
checkg##TYPE (void) \
{ \
- check##TYPE ( g1s##TYPE, (TYPE2)1); \
- check##TYPE ( g2s##TYPE, (TYPE2)2); \
- check##TYPE ( g3s##TYPE, (TYPE2)3); \
- check##TYPE ( g4s##TYPE, (TYPE2)4); \
- check##TYPE ( g5s##TYPE, (TYPE2)5); \
- check##TYPE ( g6s##TYPE, (TYPE2)6); \
- check##TYPE ( g7s##TYPE, (TYPE2)7); \
- check##TYPE ( g8s##TYPE, (TYPE2)8); \
- check##TYPE ( g9s##TYPE, (TYPE2)9); \
- check##TYPE ( g10s##TYPE, (TYPE2)10); \
- check##TYPE ( g11s##TYPE, (TYPE2)11); \
- check##TYPE ( g12s##TYPE, (TYPE2)12); \
- check##TYPE ( g13s##TYPE, (TYPE2)13); \
- check##TYPE ( g14s##TYPE, (TYPE2)14); \
- check##TYPE ( g15s##TYPE, (TYPE2)15); \
- check##TYPE ( g16s##TYPE, (TYPE2)16); \
+ check##TYPE ( g1s##TYPE, &NAME##values[1]); \
+ check##TYPE ( g2s##TYPE, &NAME##values[2]); \
+ check##TYPE ( g3s##TYPE, &NAME##values[3]); \
+ check##TYPE ( g4s##TYPE, &NAME##values[4]); \
+ check##TYPE ( g5s##TYPE, &NAME##values[5]); \
+ check##TYPE ( g6s##TYPE, &NAME##values[6]); \
+ check##TYPE ( g7s##TYPE, &NAME##values[7]); \
+ check##TYPE ( g8s##TYPE, &NAME##values[8]); \
+ check##TYPE ( g9s##TYPE, &NAME##values[9]); \
+ check##TYPE ( g10s##TYPE, &NAME##values[10]); \
+ check##TYPE ( g11s##TYPE, &NAME##values[11]); \
+ check##TYPE ( g12s##TYPE, &NAME##values[12]); \
+ check##TYPE ( g13s##TYPE, &NAME##values[13]); \
+ check##TYPE ( g14s##TYPE, &NAME##values[14]); \
+ check##TYPE ( g15s##TYPE, &NAME##values[15]); \
+ check##TYPE ( g16s##TYPE, &NAME##values[16]); \
} \
\
void \
@@ -33,22 +34,22 @@ test##TYPE (TYPE s1, TYPE s2, TYPE s3, T
TYPE s9, TYPE s10, TYPE s11, TYPE s12, \
TYPE s13, TYPE s14, TYPE s15, TYPE s16) \
{ \
- check##TYPE (s1, (TYPE2)1); \
- check##TYPE (s2, (TYPE2)2); \
- check##TYPE (s3, (TYPE2)3); \
- check##TYPE (s4, (TYPE2)4); \
- check##TYPE (s5, (TYPE2)5); \
- check##TYPE (s6, (TYPE2)6); \
- check##TYPE (s7, (TYPE2)7); \
- check##TYPE (s8, (TYPE2)8); \
- check##TYPE (s9, (TYPE2)9); \
- check##TYPE (s10, (TYPE2)10); \
- check##TYPE (s11, (TYPE2)11); \
- check##TYPE (s12, (TYPE2)12); \
- check##TYPE (s13, (TYPE2)13); \
- check##TYPE (s14, (TYPE2)14); \
- check##TYPE (s15, (TYPE2)15); \
- check##TYPE (s16, (TYPE2)16); \
+ check##TYPE (s1, &NAME##values[1]); \
+ check##TYPE (s2, &NAME##values[2]); \
+ check##TYPE (s3, &NAME##values[3]); \
+ check##TYPE (s4, &NAME##values[4]); \
+ check##TYPE (s5, &NAME##values[5]); \
+ check##TYPE (s6, &NAME##values[6]); \
+ check##TYPE (s7, &NAME##values[7]); \
+ check##TYPE (s8, &NAME##values[8]); \
+ check##TYPE (s9, &NAME##values[9]); \
+ check##TYPE (s10, &NAME##values[10]); \
+ check##TYPE (s11, &NAME##values[11]); \
+ check##TYPE (s12, &NAME##values[12]); \
+ check##TYPE (s13, &NAME##values[13]); \
+ check##TYPE (s14, &NAME##values[14]); \
+ check##TYPE (s15, &NAME##values[15]); \
+ check##TYPE (s16, &NAME##values[16]); \
} \
\
void \
@@ -62,7 +63,7 @@ testva##TYPE (int n, ...) \
for (i = 0; i < n; i++) \
{ \
TYPE t = va_arg (ap, TYPE); \
- check##TYPE (t, (TYPE2)i+1); \
+ check##TYPE (t, &NAME##values[i+1]); \
} \
va_end (ap); \
} \
Index: testsuite/gcc.dg/compat/struct-by-value-11_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-11_x.c,v
retrieving revision 1.4
diff -u -p -r1.4 struct-by-value-11_x.c
--- testsuite/gcc.dg/compat/struct-by-value-11_x.c 19 Jan 2004 19:17:49 -0000 1.4
+++ testsuite/gcc.dg/compat/struct-by-value-11_x.c 26 Apr 2004 23:39:07 -0000
@@ -5,25 +5,28 @@
#include "fp-struct-test-by-value-x.h"
#ifndef SKIP_COMPLEX_INT
+extern _Complex char ccvalues[];
+extern void init_ccvalues (void);
+
DEFS(cc, _Complex char)
CHECKS(cc, _Complex char)
-TEST(Scc1, _Complex char)
-TEST(Scc2, _Complex char)
-TEST(Scc3, _Complex char)
-TEST(Scc4, _Complex char)
-TEST(Scc5, _Complex char)
-TEST(Scc6, _Complex char)
-TEST(Scc7, _Complex char)
-TEST(Scc8, _Complex char)
-TEST(Scc9, _Complex char)
-TEST(Scc10, _Complex char)
-TEST(Scc11, _Complex char)
-TEST(Scc12, _Complex char)
-TEST(Scc13, _Complex char)
-TEST(Scc14, _Complex char)
-TEST(Scc15, _Complex char)
-TEST(Scc16, _Complex char)
+TEST(cc, Scc1, _Complex char)
+TEST(cc, Scc2, _Complex char)
+TEST(cc, Scc3, _Complex char)
+TEST(cc, Scc4, _Complex char)
+TEST(cc, Scc5, _Complex char)
+TEST(cc, Scc6, _Complex char)
+TEST(cc, Scc7, _Complex char)
+TEST(cc, Scc8, _Complex char)
+TEST(cc, Scc9, _Complex char)
+TEST(cc, Scc10, _Complex char)
+TEST(cc, Scc11, _Complex char)
+TEST(cc, Scc12, _Complex char)
+TEST(cc, Scc13, _Complex char)
+TEST(cc, Scc14, _Complex char)
+TEST(cc, Scc15, _Complex char)
+TEST(cc, Scc16, _Complex char)
#endif
#undef T
@@ -32,6 +35,7 @@ void
struct_by_value_11_x ()
{
#ifndef SKIP_COMPLEX_INT
+init_ccvalues ();
DEBUG_INIT
#define T(TYPE, MTYPE) testit##TYPE ();
Index: testsuite/gcc.dg/compat/struct-by-value-11_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-11_y.c,v
retrieving revision 1.2
diff -u -p -r1.2 struct-by-value-11_y.c
--- testsuite/gcc.dg/compat/struct-by-value-11_y.c 19 Jan 2004 19:17:49 -0000 1.2
+++ testsuite/gcc.dg/compat/struct-by-value-11_y.c 26 Apr 2004 23:39:07 -0000
@@ -13,23 +13,34 @@ const int test_va = 1;
#include "fp-struct-test-by-value-y.h"
#ifndef SKIP_COMPLEX_INT
-DEFS(cc,_Complex char)
-INITS(cc, _Complex char)
+#define VALUES_LEN 32
+char _Complex ccvalues[VALUES_LEN];
+void
+init_ccvalues (void)
+{
+ int i, j;
-TEST(Scc1, _Complex char)
-TEST(Scc2, _Complex char)
-TEST(Scc3, _Complex char)
-TEST(Scc4, _Complex char)
-TEST(Scc5, _Complex char)
-TEST(Scc6, _Complex char)
-TEST(Scc7, _Complex char)
-TEST(Scc8, _Complex char)
-TEST(Scc9, _Complex char)
-TEST(Scc10, _Complex char)
-TEST(Scc11, _Complex char)
-TEST(Scc12, _Complex char)
-TEST(Scc13, _Complex char)
-TEST(Scc14, _Complex char)
-TEST(Scc15, _Complex char)
-TEST(Scc16, _Complex char)
+ for (i = 0; i < VALUES_LEN; i++)
+ ccvalues[i] = (i+1) + (i+VALUES_LEN*1i);
+}
+
+DEFS(cc,char _Complex)
+INITS(cc, char _Complex)
+
+TEST(cc, Scc1, char _Complex)
+TEST(cc, Scc2, char _Complex)
+TEST(cc, Scc3, char _Complex)
+TEST(cc, Scc4, char _Complex)
+TEST(cc, Scc5, char _Complex)
+TEST(cc, Scc6, char _Complex)
+TEST(cc, Scc7, char _Complex)
+TEST(cc, Scc8, char _Complex)
+TEST(cc, Scc9, char _Complex)
+TEST(cc, Scc10, char _Complex)
+TEST(cc, Scc11, char _Complex)
+TEST(cc, Scc12, char _Complex)
+TEST(cc, Scc13, char _Complex)
+TEST(cc, Scc14, char _Complex)
+TEST(cc, Scc15, char _Complex)
+TEST(cc, Scc16, char _Complex)
#endif
Index: testsuite/gcc.dg/compat/struct-by-value-12_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-12_x.c,v
retrieving revision 1.4
diff -u -p -r1.4 struct-by-value-12_x.c
--- testsuite/gcc.dg/compat/struct-by-value-12_x.c 19 Jan 2004 19:17:49 -0000 1.4
+++ testsuite/gcc.dg/compat/struct-by-value-12_x.c 26 Apr 2004 23:39:07 -0000
@@ -5,25 +5,28 @@
#include "fp-struct-test-by-value-x.h"
#ifndef SKIP_COMPLEX_INT
+extern _Complex short csvalues[];
+extern void init_csvalues (void);
+
DEFS(cs, _Complex short)
CHECKS(cs, _Complex short)
-TEST(Scs1, _Complex short)
-TEST(Scs2, _Complex short)
-TEST(Scs3, _Complex short)
-TEST(Scs4, _Complex short)
-TEST(Scs5, _Complex short)
-TEST(Scs6, _Complex short)
-TEST(Scs7, _Complex short)
-TEST(Scs8, _Complex short)
-TEST(Scs9, _Complex short)
-TEST(Scs10, _Complex short)
-TEST(Scs11, _Complex short)
-TEST(Scs12, _Complex short)
-TEST(Scs13, _Complex short)
-TEST(Scs14, _Complex short)
-TEST(Scs15, _Complex short)
-TEST(Scs16, _Complex short)
+TEST(cs, Scs1, _Complex short)
+TEST(cs, Scs2, _Complex short)
+TEST(cs, Scs3, _Complex short)
+TEST(cs, Scs4, _Complex short)
+TEST(cs, Scs5, _Complex short)
+TEST(cs, Scs6, _Complex short)
+TEST(cs, Scs7, _Complex short)
+TEST(cs, Scs8, _Complex short)
+TEST(cs, Scs9, _Complex short)
+TEST(cs, Scs10, _Complex short)
+TEST(cs, Scs11, _Complex short)
+TEST(cs, Scs12, _Complex short)
+TEST(cs, Scs13, _Complex short)
+TEST(cs, Scs14, _Complex short)
+TEST(cs, Scs15, _Complex short)
+TEST(cs, Scs16, _Complex short)
#endif
#undef T
@@ -32,6 +35,7 @@ void
struct_by_value_12_x ()
{
#ifndef SKIP_COMPLEX_INT
+init_csvalues ();
DEBUG_INIT
#define T(TYPE, MTYPE) testit##TYPE ();
Index: testsuite/gcc.dg/compat/struct-by-value-12_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-12_y.c,v
retrieving revision 1.2
diff -u -p -r1.2 struct-by-value-12_y.c
--- testsuite/gcc.dg/compat/struct-by-value-12_y.c 19 Jan 2004 19:17:49 -0000 1.2
+++ testsuite/gcc.dg/compat/struct-by-value-12_y.c 26 Apr 2004 23:39:07 -0000
@@ -13,23 +13,34 @@ const int test_va = 1;
#include "fp-struct-test-by-value-y.h"
#ifndef SKIP_COMPLEX_INT
-DEFS(cs,_Complex short)
-INITS(cs, _Complex short)
+#define VALUES_LEN 32
+short _Complex csvalues[VALUES_LEN];
+void
+init_csvalues (void)
+{
+ int i, j;
-TEST(Scs1, _Complex short)
-TEST(Scs2, _Complex short)
-TEST(Scs3, _Complex short)
-TEST(Scs4, _Complex short)
-TEST(Scs5, _Complex short)
-TEST(Scs6, _Complex short)
-TEST(Scs7, _Complex short)
-TEST(Scs8, _Complex short)
-TEST(Scs9, _Complex short)
-TEST(Scs10, _Complex short)
-TEST(Scs11, _Complex short)
-TEST(Scs12, _Complex short)
-TEST(Scs13, _Complex short)
-TEST(Scs14, _Complex short)
-TEST(Scs15, _Complex short)
-TEST(Scs16, _Complex short)
+ for (i = 0; i < VALUES_LEN; i++)
+ csvalues[i] = (i+1) + (i+VALUES_LEN*1i);
+}
+
+DEFS(cs,short _Complex)
+INITS(cs, short _Complex)
+
+TEST(cs, Scs1, short _Complex)
+TEST(cs, Scs2, short _Complex)
+TEST(cs, Scs3, short _Complex)
+TEST(cs, Scs4, short _Complex)
+TEST(cs, Scs5, short _Complex)
+TEST(cs, Scs6, short _Complex)
+TEST(cs, Scs7, short _Complex)
+TEST(cs, Scs8, short _Complex)
+TEST(cs, Scs9, short _Complex)
+TEST(cs, Scs10, short _Complex)
+TEST(cs, Scs11, short _Complex)
+TEST(cs, Scs12, short _Complex)
+TEST(cs, Scs13, short _Complex)
+TEST(cs, Scs14, short _Complex)
+TEST(cs, Scs15, short _Complex)
+TEST(cs, Scs16, short _Complex)
#endif
Index: testsuite/gcc.dg/compat/struct-by-value-13_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-13_x.c,v
retrieving revision 1.4
diff -u -p -r1.4 struct-by-value-13_x.c
--- testsuite/gcc.dg/compat/struct-by-value-13_x.c 19 Jan 2004 19:17:49 -0000 1.4
+++ testsuite/gcc.dg/compat/struct-by-value-13_x.c 26 Apr 2004 23:39:07 -0000
@@ -5,25 +5,28 @@
#include "fp-struct-test-by-value-x.h"
#ifndef SKIP_COMPLEX_INT
+extern _Complex int civalues[];
+extern void init_civalues (void);
+
DEFS(ci, _Complex int)
CHECKS(ci, _Complex int)
-TEST(Sci1, _Complex int)
-TEST(Sci2, _Complex int)
-TEST(Sci3, _Complex int)
-TEST(Sci4, _Complex int)
-TEST(Sci5, _Complex int)
-TEST(Sci6, _Complex int)
-TEST(Sci7, _Complex int)
-TEST(Sci8, _Complex int)
-TEST(Sci9, _Complex int)
-TEST(Sci10, _Complex int)
-TEST(Sci11, _Complex int)
-TEST(Sci12, _Complex int)
-TEST(Sci13, _Complex int)
-TEST(Sci14, _Complex int)
-TEST(Sci15, _Complex int)
-TEST(Sci16, _Complex int)
+TEST(ci, Sci1, _Complex int)
+TEST(ci, Sci2, _Complex int)
+TEST(ci, Sci3, _Complex int)
+TEST(ci, Sci4, _Complex int)
+TEST(ci, Sci5, _Complex int)
+TEST(ci, Sci6, _Complex int)
+TEST(ci, Sci7, _Complex int)
+TEST(ci, Sci8, _Complex int)
+TEST(ci, Sci9, _Complex int)
+TEST(ci, Sci10, _Complex int)
+TEST(ci, Sci11, _Complex int)
+TEST(ci, Sci12, _Complex int)
+TEST(ci, Sci13, _Complex int)
+TEST(ci, Sci14, _Complex int)
+TEST(ci, Sci15, _Complex int)
+TEST(ci, Sci16, _Complex int)
#endif
#undef T
@@ -32,6 +35,7 @@ void
struct_by_value_13_x ()
{
#ifndef SKIP_COMPLEX_INT
+init_civalues ();
DEBUG_INIT
#define T(TYPE, MTYPE) testit##TYPE ();
Index: testsuite/gcc.dg/compat/struct-by-value-13_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-13_y.c,v
retrieving revision 1.2
diff -u -p -r1.2 struct-by-value-13_y.c
--- testsuite/gcc.dg/compat/struct-by-value-13_y.c 19 Jan 2004 19:17:49 -0000 1.2
+++ testsuite/gcc.dg/compat/struct-by-value-13_y.c 26 Apr 2004 23:39:07 -0000
@@ -13,23 +13,34 @@ const int test_va = 1;
#include "fp-struct-test-by-value-y.h"
#ifndef SKIP_COMPLEX_INT
-DEFS(ci,_Complex int)
-INITS(ci, _Complex int)
+#define VALUES_LEN 32
+int _Complex civalues[VALUES_LEN];
+void
+init_civalues (void)
+{
+ int i, j;
-TEST(Sci1, _Complex int)
-TEST(Sci2, _Complex int)
-TEST(Sci3, _Complex int)
-TEST(Sci4, _Complex int)
-TEST(Sci5, _Complex int)
-TEST(Sci6, _Complex int)
-TEST(Sci7, _Complex int)
-TEST(Sci8, _Complex int)
-TEST(Sci9, _Complex int)
-TEST(Sci10, _Complex int)
-TEST(Sci11, _Complex int)
-TEST(Sci12, _Complex int)
-TEST(Sci13, _Complex int)
-TEST(Sci14, _Complex int)
-TEST(Sci15, _Complex int)
-TEST(Sci16, _Complex int)
+ for (i = 0; i < VALUES_LEN; i++)
+ civalues[i] = (i+1) + (i+VALUES_LEN*1i);
+}
+
+DEFS(ci,int _Complex)
+INITS(ci, int _Complex)
+
+TEST(ci, Sci1, int _Complex)
+TEST(ci, Sci2, int _Complex)
+TEST(ci, Sci3, int _Complex)
+TEST(ci, Sci4, int _Complex)
+TEST(ci, Sci5, int _Complex)
+TEST(ci, Sci6, int _Complex)
+TEST(ci, Sci7, int _Complex)
+TEST(ci, Sci8, int _Complex)
+TEST(ci, Sci9, int _Complex)
+TEST(ci, Sci10, int _Complex)
+TEST(ci, Sci11, int _Complex)
+TEST(ci, Sci12, int _Complex)
+TEST(ci, Sci13, int _Complex)
+TEST(ci, Sci14, int _Complex)
+TEST(ci, Sci15, int _Complex)
+TEST(ci, Sci16, int _Complex)
#endif
Index: testsuite/gcc.dg/compat/struct-by-value-14_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-14_x.c,v
retrieving revision 1.4
diff -u -p -r1.4 struct-by-value-14_x.c
--- testsuite/gcc.dg/compat/struct-by-value-14_x.c 19 Jan 2004 19:17:49 -0000 1.4
+++ testsuite/gcc.dg/compat/struct-by-value-14_x.c 26 Apr 2004 23:39:07 -0000
@@ -5,25 +5,28 @@
#include "fp-struct-test-by-value-x.h"
#ifndef SKIP_COMPLEX_INT
+extern _Complex long clvalues[];
+extern void init_clvalues (void);
+
DEFS(cl, _Complex long)
CHECKS(cl, _Complex long)
-TEST(Scl1, _Complex long)
-TEST(Scl2, _Complex long)
-TEST(Scl3, _Complex long)
-TEST(Scl4, _Complex long)
-TEST(Scl5, _Complex long)
-TEST(Scl6, _Complex long)
-TEST(Scl7, _Complex long)
-TEST(Scl8, _Complex long)
-TEST(Scl9, _Complex long)
-TEST(Scl10, _Complex long)
-TEST(Scl11, _Complex long)
-TEST(Scl12, _Complex long)
-TEST(Scl13, _Complex long)
-TEST(Scl14, _Complex long)
-TEST(Scl15, _Complex long)
-TEST(Scl16, _Complex long)
+TEST(cl, Scl1, _Complex long)
+TEST(cl, Scl2, _Complex long)
+TEST(cl, Scl3, _Complex long)
+TEST(cl, Scl4, _Complex long)
+TEST(cl, Scl5, _Complex long)
+TEST(cl, Scl6, _Complex long)
+TEST(cl, Scl7, _Complex long)
+TEST(cl, Scl8, _Complex long)
+TEST(cl, Scl9, _Complex long)
+TEST(cl, Scl10, _Complex long)
+TEST(cl, Scl11, _Complex long)
+TEST(cl, Scl12, _Complex long)
+TEST(cl, Scl13, _Complex long)
+TEST(cl, Scl14, _Complex long)
+TEST(cl, Scl15, _Complex long)
+TEST(cl, Scl16, _Complex long)
#endif
#undef T
@@ -32,6 +35,7 @@ void
struct_by_value_14_x ()
{
#ifndef SKIP_COMPLEX_INT
+init_clvalues ();
DEBUG_INIT
#define T(TYPE, MTYPE) testit##TYPE ();
Index: testsuite/gcc.dg/compat/struct-by-value-14_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-14_y.c,v
retrieving revision 1.2
diff -u -p -r1.2 struct-by-value-14_y.c
--- testsuite/gcc.dg/compat/struct-by-value-14_y.c 19 Jan 2004 19:17:49 -0000 1.2
+++ testsuite/gcc.dg/compat/struct-by-value-14_y.c 26 Apr 2004 23:39:07 -0000
@@ -13,23 +13,34 @@ const int test_va = 1;
#include "fp-struct-test-by-value-y.h"
#ifndef SKIP_COMPLEX_INT
-DEFS(cl,_Complex long)
-INITS(cl, _Complex long)
+#define VALUES_LEN 32
+_Complex long clvalues[VALUES_LEN];
+void
+init_clvalues (void)
+{
+ int i, j;
-TEST(Scl1, _Complex long)
-TEST(Scl2, _Complex long)
-TEST(Scl3, _Complex long)
-TEST(Scl4, _Complex long)
-TEST(Scl5, _Complex long)
-TEST(Scl6, _Complex long)
-TEST(Scl7, _Complex long)
-TEST(Scl8, _Complex long)
-TEST(Scl9, _Complex long)
-TEST(Scl10, _Complex long)
-TEST(Scl11, _Complex long)
-TEST(Scl12, _Complex long)
-TEST(Scl13, _Complex long)
-TEST(Scl14, _Complex long)
-TEST(Scl15, _Complex long)
-TEST(Scl16, _Complex long)
+ for (i = 0; i < VALUES_LEN; i++)
+ clvalues[i] = (i+1) + (i+VALUES_LEN*1i);
+}
+
+DEFS(cl,long _Complex)
+INITS(cl, long _Complex)
+
+TEST(cl, Scl1, long _Complex)
+TEST(cl, Scl2, long _Complex)
+TEST(cl, Scl3, long _Complex)
+TEST(cl, Scl4, long _Complex)
+TEST(cl, Scl5, long _Complex)
+TEST(cl, Scl6, long _Complex)
+TEST(cl, Scl7, long _Complex)
+TEST(cl, Scl8, long _Complex)
+TEST(cl, Scl9, long _Complex)
+TEST(cl, Scl10, long _Complex)
+TEST(cl, Scl11, long _Complex)
+TEST(cl, Scl12, long _Complex)
+TEST(cl, Scl13, long _Complex)
+TEST(cl, Scl14, long _Complex)
+TEST(cl, Scl15, long _Complex)
+TEST(cl, Scl16, long _Complex)
#endif
Index: testsuite/gcc.dg/compat/struct-by-value-15_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-15_x.c,v
retrieving revision 1.4
diff -u -p -r1.4 struct-by-value-15_x.c
--- testsuite/gcc.dg/compat/struct-by-value-15_x.c 19 Jan 2004 19:17:49 -0000 1.4
+++ testsuite/gcc.dg/compat/struct-by-value-15_x.c 26 Apr 2004 23:39:07 -0000
@@ -5,25 +5,28 @@
#include "fp-struct-test-by-value-x.h"
#ifndef SKIP_COMPLEX_INT
+extern _Complex long long cllvalues[];
+extern void init_cllvalues (void);
+
DEFS(cll, _Complex long long)
CHECKS(cll, _Complex long long)
-TEST(Scll1, _Complex long long)
-TEST(Scll2, _Complex long long)
-TEST(Scll3, _Complex long long)
-TEST(Scll4, _Complex long long)
-TEST(Scll5, _Complex long long)
-TEST(Scll6, _Complex long long)
-TEST(Scll7, _Complex long long)
-TEST(Scll8, _Complex long long)
-TEST(Scll9, _Complex long long)
-TEST(Scll10, _Complex long long)
-TEST(Scll11, _Complex long long)
-TEST(Scll12, _Complex long long)
-TEST(Scll13, _Complex long long)
-TEST(Scll14, _Complex long long)
-TEST(Scll15, _Complex long long)
-TEST(Scll16, _Complex long long)
+TEST(cll, Scll1, _Complex long long)
+TEST(cll, Scll2, _Complex long long)
+TEST(cll, Scll3, _Complex long long)
+TEST(cll, Scll4, _Complex long long)
+TEST(cll, Scll5, _Complex long long)
+TEST(cll, Scll6, _Complex long long)
+TEST(cll, Scll7, _Complex long long)
+TEST(cll, Scll8, _Complex long long)
+TEST(cll, Scll9, _Complex long long)
+TEST(cll, Scll10, _Complex long long)
+TEST(cll, Scll11, _Complex long long)
+TEST(cll, Scll12, _Complex long long)
+TEST(cll, Scll13, _Complex long long)
+TEST(cll, Scll14, _Complex long long)
+TEST(cll, Scll15, _Complex long long)
+TEST(cll, Scll16, _Complex long long)
#endif
#undef T
@@ -32,6 +35,7 @@ void
struct_by_value_15_x ()
{
#ifndef SKIP_COMPLEX_INT
+init_cllvalues ();
DEBUG_INIT
#define T(TYPE, MTYPE) testit##TYPE ();
Index: testsuite/gcc.dg/compat/struct-by-value-15_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-15_y.c,v
retrieving revision 1.2
diff -u -p -r1.2 struct-by-value-15_y.c
--- testsuite/gcc.dg/compat/struct-by-value-15_y.c 19 Jan 2004 19:17:49 -0000 1.2
+++ testsuite/gcc.dg/compat/struct-by-value-15_y.c 26 Apr 2004 23:39:07 -0000
@@ -13,23 +13,34 @@ const int test_va = 1;
#include "fp-struct-test-by-value-y.h"
#ifndef SKIP_COMPLEX_INT
-DEFS(cll,_Complex long long)
-INITS(cll, _Complex long long)
+#define VALUES_LEN 32
+_Complex long long cllvalues[VALUES_LEN];
+void
+init_cllvalues (void)
+{
+ int i, j;
-TEST(Scll1, _Complex long long)
-TEST(Scll2, _Complex long long)
-TEST(Scll3, _Complex long long)
-TEST(Scll4, _Complex long long)
-TEST(Scll5, _Complex long long)
-TEST(Scll6, _Complex long long)
-TEST(Scll7, _Complex long long)
-TEST(Scll8, _Complex long long)
-TEST(Scll9, _Complex long long)
-TEST(Scll10, _Complex long long)
-TEST(Scll11, _Complex long long)
-TEST(Scll12, _Complex long long)
-TEST(Scll13, _Complex long long)
-TEST(Scll14, _Complex long long)
-TEST(Scll15, _Complex long long)
-TEST(Scll16, _Complex long long)
+ for (i = 0; i < VALUES_LEN; i++)
+ cllvalues[i] = (i+1) + (i+VALUES_LEN*1i);
+}
+
+DEFS(cll,long long _Complex)
+INITS(cll, long long _Complex)
+
+TEST(cll, Scll1, long long _Complex)
+TEST(cll, Scll2, long long _Complex)
+TEST(cll, Scll3, long long _Complex)
+TEST(cll, Scll4, long long _Complex)
+TEST(cll, Scll5, long long _Complex)
+TEST(cll, Scll6, long long _Complex)
+TEST(cll, Scll7, long long _Complex)
+TEST(cll, Scll8, long long _Complex)
+TEST(cll, Scll9, long long _Complex)
+TEST(cll, Scll10, long long _Complex)
+TEST(cll, Scll11, long long _Complex)
+TEST(cll, Scll12, long long _Complex)
+TEST(cll, Scll13, long long _Complex)
+TEST(cll, Scll14, long long _Complex)
+TEST(cll, Scll15, long long _Complex)
+TEST(cll, Scll16, long long _Complex)
#endif
Index: testsuite/gcc.dg/compat/struct-by-value-16_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-16_x.c,v
retrieving revision 1.3
diff -u -p -r1.3 struct-by-value-16_x.c
--- testsuite/gcc.dg/compat/struct-by-value-16_x.c 3 Jul 2003 18:31:59 -0000 1.3
+++ testsuite/gcc.dg/compat/struct-by-value-16_x.c 26 Apr 2004 23:39:07 -0000
@@ -4,51 +4,55 @@
#include "fp-struct-check.h"
#include "fp-struct-test-by-value-x.h"
-DEFS(cf, _Complex float)
-CHECKS(cf, _Complex float)
+extern float _Complex cfvalues[];
+extern void init_cfvalues (void);
-TEST(Scf1, _Complex float)
-TEST(Scf2, _Complex float)
-TEST(Scf3, _Complex float)
-TEST(Scf4, _Complex float)
-TEST(Scf5, _Complex float)
-TEST(Scf6, _Complex float)
-TEST(Scf7, _Complex float)
-TEST(Scf8, _Complex float)
-TEST(Scf9, _Complex float)
-TEST(Scf10, _Complex float)
-TEST(Scf11, _Complex float)
-TEST(Scf12, _Complex float)
-TEST(Scf13, _Complex float)
-TEST(Scf14, _Complex float)
-TEST(Scf15, _Complex float)
-TEST(Scf16, _Complex float)
+DEFS(cf, float _Complex)
+CHECKS(cf, float _Complex)
+
+TEST(cf, Scf1, float _Complex)
+TEST(cf, Scf2, float _Complex)
+TEST(cf, Scf3, float _Complex)
+TEST(cf, Scf4, float _Complex)
+TEST(cf, Scf5, float _Complex)
+TEST(cf, Scf6, float _Complex)
+TEST(cf, Scf7, float _Complex)
+TEST(cf, Scf8, float _Complex)
+TEST(cf, Scf9, float _Complex)
+TEST(cf, Scf10, float _Complex)
+TEST(cf, Scf11, float _Complex)
+TEST(cf, Scf12, float _Complex)
+TEST(cf, Scf13, float _Complex)
+TEST(cf, Scf14, float _Complex)
+TEST(cf, Scf15, float _Complex)
+TEST(cf, Scf16, float _Complex)
#undef T
void
struct_by_value_16_x ()
{
+init_cfvalues ();
DEBUG_INIT
#define T(TYPE, MTYPE) testit##TYPE ();
-T(Scf1, _Complex float)
-T(Scf2, _Complex float)
-T(Scf3, _Complex float)
-T(Scf4, _Complex float)
-T(Scf5, _Complex float)
-T(Scf6, _Complex float)
-T(Scf7, _Complex float)
-T(Scf8, _Complex float)
-T(Scf9, _Complex float)
-T(Scf10, _Complex float)
-T(Scf11, _Complex float)
-T(Scf12, _Complex float)
-T(Scf13, _Complex float)
-T(Scf14, _Complex float)
-T(Scf15, _Complex float)
-T(Scf16, _Complex float)
+T(Scf1, float _Complex)
+T(Scf2, float _Complex)
+T(Scf3, float _Complex)
+T(Scf4, float _Complex)
+T(Scf5, float _Complex)
+T(Scf6, float _Complex)
+T(Scf7, float _Complex)
+T(Scf8, float _Complex)
+T(Scf9, float _Complex)
+T(Scf10, float _Complex)
+T(Scf11, float _Complex)
+T(Scf12, float _Complex)
+T(Scf13, float _Complex)
+T(Scf14, float _Complex)
+T(Scf15, float _Complex)
+T(Scf16, float _Complex)
DEBUG_FINI
Index: testsuite/gcc.dg/compat/struct-by-value-16_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-16_y.c,v
retrieving revision 1.2
diff -u -p -r1.2 struct-by-value-16_y.c
--- testsuite/gcc.dg/compat/struct-by-value-16_y.c 19 Jan 2004 19:17:49 -0000 1.2
+++ testsuite/gcc.dg/compat/struct-by-value-16_y.c 26 Apr 2004 23:39:07 -0000
@@ -1,4 +1,5 @@
#include <stdarg.h>
+#include <complex.h>
#include "compat-common.h"
@@ -12,22 +13,33 @@ const int test_va = 1;
#include "fp-struct-init.h"
#include "fp-struct-test-by-value-y.h"
-DEFS(cf,_Complex float)
-INITS(cf, _Complex float)
+#define VALUES_LEN 32
+float _Complex cfvalues[VALUES_LEN];
+void
+init_cfvalues (void)
+{
+ int i, j;
-TEST(Scf1, _Complex float)
-TEST(Scf2, _Complex float)
-TEST(Scf3, _Complex float)
-TEST(Scf4, _Complex float)
-TEST(Scf5, _Complex float)
-TEST(Scf6, _Complex float)
-TEST(Scf7, _Complex float)
-TEST(Scf8, _Complex float)
-TEST(Scf9, _Complex float)
-TEST(Scf10, _Complex float)
-TEST(Scf11, _Complex float)
-TEST(Scf12, _Complex float)
-TEST(Scf13, _Complex float)
-TEST(Scf14, _Complex float)
-TEST(Scf15, _Complex float)
-TEST(Scf16, _Complex float)
+ for (i = 0; i < VALUES_LEN; i++)
+ cfvalues[i] = (i+1.1f) + (2.1*I*(i+VALUES_LEN));
+}
+
+DEFS(cf,float _Complex)
+INITS(cf, float _Complex)
+
+TEST(cf, Scf1, float _Complex)
+TEST(cf, Scf2, float _Complex)
+TEST(cf, Scf3, float _Complex)
+TEST(cf, Scf4, float _Complex)
+TEST(cf, Scf5, float _Complex)
+TEST(cf, Scf6, float _Complex)
+TEST(cf, Scf7, float _Complex)
+TEST(cf, Scf8, float _Complex)
+TEST(cf, Scf9, float _Complex)
+TEST(cf, Scf10, float _Complex)
+TEST(cf, Scf11, float _Complex)
+TEST(cf, Scf12, float _Complex)
+TEST(cf, Scf13, float _Complex)
+TEST(cf, Scf14, float _Complex)
+TEST(cf, Scf15, float _Complex)
+TEST(cf, Scf16, float _Complex)
Index: testsuite/gcc.dg/compat/struct-by-value-17_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-17_x.c,v
retrieving revision 1.3
diff -u -p -r1.3 struct-by-value-17_x.c
--- testsuite/gcc.dg/compat/struct-by-value-17_x.c 3 Jul 2003 18:31:59 -0000 1.3
+++ testsuite/gcc.dg/compat/struct-by-value-17_x.c 26 Apr 2004 23:39:07 -0000
@@ -4,51 +4,55 @@
#include "fp-struct-check.h"
#include "fp-struct-test-by-value-x.h"
-DEFS(cd, _Complex double)
-CHECKS(cd, _Complex double)
+extern double _Complex cdvalues[];
+extern void init_cdvalues (void);
-TEST(Scd1, _Complex double)
-TEST(Scd2, _Complex double)
-TEST(Scd3, _Complex double)
-TEST(Scd4, _Complex double)
-TEST(Scd5, _Complex double)
-TEST(Scd6, _Complex double)
-TEST(Scd7, _Complex double)
-TEST(Scd8, _Complex double)
-TEST(Scd9, _Complex double)
-TEST(Scd10, _Complex double)
-TEST(Scd11, _Complex double)
-TEST(Scd12, _Complex double)
-TEST(Scd13, _Complex double)
-TEST(Scd14, _Complex double)
-TEST(Scd15, _Complex double)
-TEST(Scd16, _Complex double)
+DEFS(cd, double _Complex)
+CHECKS(cd, double _Complex)
+
+TEST(cd, Scd1, double _Complex)
+TEST(cd, Scd2, double _Complex)
+TEST(cd, Scd3, double _Complex)
+TEST(cd, Scd4, double _Complex)
+TEST(cd, Scd5, double _Complex)
+TEST(cd, Scd6, double _Complex)
+TEST(cd, Scd7, double _Complex)
+TEST(cd, Scd8, double _Complex)
+TEST(cd, Scd9, double _Complex)
+TEST(cd, Scd10, double _Complex)
+TEST(cd, Scd11, double _Complex)
+TEST(cd, Scd12, double _Complex)
+TEST(cd, Scd13, double _Complex)
+TEST(cd, Scd14, double _Complex)
+TEST(cd, Scd15, double _Complex)
+TEST(cd, Scd16, double _Complex)
#undef T
void
struct_by_value_17_x ()
{
+init_cdvalues ();
DEBUG_INIT
#define T(TYPE, MTYPE) testit##TYPE ();
-T(Scd1, _Complex double)
-T(Scd2, _Complex double)
-T(Scd3, _Complex double)
-T(Scd4, _Complex double)
-T(Scd5, _Complex double)
-T(Scd6, _Complex double)
-T(Scd7, _Complex double)
-T(Scd8, _Complex double)
-T(Scd9, _Complex double)
-T(Scd10, _Complex double)
-T(Scd11, _Complex double)
-T(Scd12, _Complex double)
-T(Scd13, _Complex double)
-T(Scd14, _Complex double)
-T(Scd15, _Complex double)
-T(Scd16, _Complex double)
+T(Scd1, double _Complex)
+T(Scd2, double _Complex)
+T(Scd3, double _Complex)
+T(Scd4, double _Complex)
+T(Scd5, double _Complex)
+T(Scd6, double _Complex)
+T(Scd7, double _Complex)
+T(Scd8, double _Complex)
+T(Scd9, double _Complex)
+T(Scd10, double _Complex)
+T(Scd11, double _Complex)
+T(Scd12, double _Complex)
+T(Scd13, double _Complex)
+T(Scd14, double _Complex)
+T(Scd15, double _Complex)
+T(Scd16, double _Complex)
DEBUG_FINI
Index: testsuite/gcc.dg/compat/struct-by-value-17_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-17_y.c,v
retrieving revision 1.2
diff -u -p -r1.2 struct-by-value-17_y.c
--- testsuite/gcc.dg/compat/struct-by-value-17_y.c 19 Jan 2004 19:17:49 -0000 1.2
+++ testsuite/gcc.dg/compat/struct-by-value-17_y.c 26 Apr 2004 23:39:07 -0000
@@ -1,4 +1,5 @@
#include <stdarg.h>
+#include <complex.h>
#include "compat-common.h"
@@ -12,22 +13,33 @@ const int test_va = 1;
#include "fp-struct-init.h"
#include "fp-struct-test-by-value-y.h"
-DEFS(cd,_Complex double)
-INITS(cd, _Complex double)
+#define VALUES_LEN 32
+double _Complex cdvalues[VALUES_LEN];
+void
+init_cdvalues (void)
+{
+ int i, j;
-TEST(Scd1, _Complex double)
-TEST(Scd2, _Complex double)
-TEST(Scd3, _Complex double)
-TEST(Scd4, _Complex double)
-TEST(Scd5, _Complex double)
-TEST(Scd6, _Complex double)
-TEST(Scd7, _Complex double)
-TEST(Scd8, _Complex double)
-TEST(Scd9, _Complex double)
-TEST(Scd10, _Complex double)
-TEST(Scd11, _Complex double)
-TEST(Scd12, _Complex double)
-TEST(Scd13, _Complex double)
-TEST(Scd14, _Complex double)
-TEST(Scd15, _Complex double)
-TEST(Scd16, _Complex double)
+ for (i = 0; i < VALUES_LEN; i++)
+ cdvalues[i] = (i+1.1) + (2.1*I*(i+VALUES_LEN));
+}
+
+DEFS(cd,double _Complex)
+INITS(cd, double _Complex)
+
+TEST(cd, Scd1, double _Complex)
+TEST(cd, Scd2, double _Complex)
+TEST(cd, Scd3, double _Complex)
+TEST(cd, Scd4, double _Complex)
+TEST(cd, Scd5, double _Complex)
+TEST(cd, Scd6, double _Complex)
+TEST(cd, Scd7, double _Complex)
+TEST(cd, Scd8, double _Complex)
+TEST(cd, Scd9, double _Complex)
+TEST(cd, Scd10, double _Complex)
+TEST(cd, Scd11, double _Complex)
+TEST(cd, Scd12, double _Complex)
+TEST(cd, Scd13, double _Complex)
+TEST(cd, Scd14, double _Complex)
+TEST(cd, Scd15, double _Complex)
+TEST(cd, Scd16, double _Complex)
Index: testsuite/gcc.dg/compat/struct-by-value-18_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-18_x.c,v
retrieving revision 1.3
diff -u -p -r1.3 struct-by-value-18_x.c
--- testsuite/gcc.dg/compat/struct-by-value-18_x.c 3 Jul 2003 18:31:59 -0000 1.3
+++ testsuite/gcc.dg/compat/struct-by-value-18_x.c 26 Apr 2004 23:39:07 -0000
@@ -4,51 +4,55 @@
#include "fp-struct-check.h"
#include "fp-struct-test-by-value-x.h"
-DEFS(cld, _Complex long double)
-CHECKS(cld, _Complex long double)
+extern long double _Complex cldvalues[];
+extern void init_cldvalues (void);
-TEST(Scld1, _Complex long double)
-TEST(Scld2, _Complex long double)
-TEST(Scld3, _Complex long double)
-TEST(Scld4, _Complex long double)
-TEST(Scld5, _Complex long double)
-TEST(Scld6, _Complex long double)
-TEST(Scld7, _Complex long double)
-TEST(Scld8, _Complex long double)
-TEST(Scld9, _Complex long double)
-TEST(Scld10, _Complex long double)
-TEST(Scld11, _Complex long double)
-TEST(Scld12, _Complex long double)
-TEST(Scld13, _Complex long double)
-TEST(Scld14, _Complex long double)
-TEST(Scld15, _Complex long double)
-TEST(Scld16, _Complex long double)
+DEFS(cld, long double _Complex)
+CHECKS(cld, long double _Complex)
+
+TEST(cld, Scld1, long double _Complex)
+TEST(cld, Scld2, long double _Complex)
+TEST(cld, Scld3, long double _Complex)
+TEST(cld, Scld4, long double _Complex)
+TEST(cld, Scld5, long double _Complex)
+TEST(cld, Scld6, long double _Complex)
+TEST(cld, Scld7, long double _Complex)
+TEST(cld, Scld8, long double _Complex)
+TEST(cld, Scld9, long double _Complex)
+TEST(cld, Scld10, long double _Complex)
+TEST(cld, Scld11, long double _Complex)
+TEST(cld, Scld12, long double _Complex)
+TEST(cld, Scld13, long double _Complex)
+TEST(cld, Scld14, long double _Complex)
+TEST(cld, Scld15, long double _Complex)
+TEST(cld, Scld16, long double _Complex)
#undef T
void
struct_by_value_18_x ()
{
+init_cldvalues ();
DEBUG_INIT
#define T(TYPE, MTYPE) testit##TYPE ();
-T(Scld1, _Complex long double)
-T(Scld2, _Complex long double)
-T(Scld3, _Complex long double)
-T(Scld4, _Complex long double)
-T(Scld5, _Complex long double)
-T(Scld6, _Complex long double)
-T(Scld7, _Complex long double)
-T(Scld8, _Complex long double)
-T(Scld9, _Complex long double)
-T(Scld10, _Complex long double)
-T(Scld11, _Complex long double)
-T(Scld12, _Complex long double)
-T(Scld13, _Complex long double)
-T(Scld14, _Complex long double)
-T(Scld15, _Complex long double)
-T(Scld16, _Complex long double)
+T(Scld1, long double _Complex)
+T(Scld2, long double _Complex)
+T(Scld3, long double _Complex)
+T(Scld4, long double _Complex)
+T(Scld5, long double _Complex)
+T(Scld6, long double _Complex)
+T(Scld7, long double _Complex)
+T(Scld8, long double _Complex)
+T(Scld9, long double _Complex)
+T(Scld10, long double _Complex)
+T(Scld11, long double _Complex)
+T(Scld12, long double _Complex)
+T(Scld13, long double _Complex)
+T(Scld14, long double _Complex)
+T(Scld15, long double _Complex)
+T(Scld16, long double _Complex)
DEBUG_FINI
Index: testsuite/gcc.dg/compat/struct-by-value-18_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-18_y.c,v
retrieving revision 1.2
diff -u -p -r1.2 struct-by-value-18_y.c
--- testsuite/gcc.dg/compat/struct-by-value-18_y.c 19 Jan 2004 19:17:49 -0000 1.2
+++ testsuite/gcc.dg/compat/struct-by-value-18_y.c 26 Apr 2004 23:39:07 -0000
@@ -1,4 +1,5 @@
#include <stdarg.h>
+#include <complex.h>
#include "compat-common.h"
@@ -12,22 +13,33 @@ const int test_va = 1;
#include "fp-struct-init.h"
#include "fp-struct-test-by-value-y.h"
-DEFS(cld,_Complex long double)
-INITS(cld, _Complex long double)
+#define VALUES_LEN 32
+long double _Complex cldvalues[VALUES_LEN];
+void
+init_cldvalues (void)
+{
+ int i, j;
-TEST(Scld1, _Complex long double)
-TEST(Scld2, _Complex long double)
-TEST(Scld3, _Complex long double)
-TEST(Scld4, _Complex long double)
-TEST(Scld5, _Complex long double)
-TEST(Scld6, _Complex long double)
-TEST(Scld7, _Complex long double)
-TEST(Scld8, _Complex long double)
-TEST(Scld9, _Complex long double)
-TEST(Scld10, _Complex long double)
-TEST(Scld11, _Complex long double)
-TEST(Scld12, _Complex long double)
-TEST(Scld13, _Complex long double)
-TEST(Scld14, _Complex long double)
-TEST(Scld15, _Complex long double)
-TEST(Scld16, _Complex long double)
+ for (i = 0; i < VALUES_LEN; i++)
+ cldvalues[i] = (i+1.1l) + (1.2l*I*(i+VALUES_LEN));
+}
+
+DEFS(cld,long double _Complex)
+INITS(cld, long double _Complex)
+
+TEST(cld, Scld1, long double _Complex)
+TEST(cld, Scld2, long double _Complex)
+TEST(cld, Scld3, long double _Complex)
+TEST(cld, Scld4, long double _Complex)
+TEST(cld, Scld5, long double _Complex)
+TEST(cld, Scld6, long double _Complex)
+TEST(cld, Scld7, long double _Complex)
+TEST(cld, Scld8, long double _Complex)
+TEST(cld, Scld9, long double _Complex)
+TEST(cld, Scld10, long double _Complex)
+TEST(cld, Scld11, long double _Complex)
+TEST(cld, Scld12, long double _Complex)
+TEST(cld, Scld13, long double _Complex)
+TEST(cld, Scld14, long double _Complex)
+TEST(cld, Scld15, long double _Complex)
+TEST(cld, Scld16, long double _Complex)
Index: testsuite/gcc.dg/compat/struct-by-value-5a_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-5a_x.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-5a_x.c
--- testsuite/gcc.dg/compat/struct-by-value-5a_x.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-5a_x.c 26 Apr 2004 23:39:07 -0000
@@ -4,17 +4,19 @@
#include "fp-struct-check.h"
#include "fp-struct-test-by-value-x.h"
+extern float fvalues[];
+
DEFS(f, float)
CHECKS(f, float)
-TEST(Sf1, float)
-TEST(Sf2, float)
-TEST(Sf3, float)
-TEST(Sf4, float)
-TEST(Sf5, float)
-TEST(Sf6, float)
-TEST(Sf7, float)
-TEST(Sf8, float)
+TEST(f, Sf1, float)
+TEST(f, Sf2, float)
+TEST(f, Sf3, float)
+TEST(f, Sf4, float)
+TEST(f, Sf5, float)
+TEST(f, Sf6, float)
+TEST(f, Sf7, float)
+TEST(f, Sf8, float)
#undef T
Index: testsuite/gcc.dg/compat/struct-by-value-5a_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-5a_y.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-5a_y.c
--- testsuite/gcc.dg/compat/struct-by-value-5a_y.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-5a_y.c 26 Apr 2004 23:39:07 -0000
@@ -12,14 +12,20 @@ const int test_va = 1;
#include "fp-struct-init.h"
#include "fp-struct-test-by-value-y.h"
+float fvalues[] =
+ { 1.9f, 2.8f, 3.7f, 4.6f, 5.4f, 6.3f, 7.2f, 8.1f,
+ 9.9f, 3.3f, 6.4f, 5.3f, 4.2f, 3.1f, 9.7f, 8.6f,
+ 7.5f, 6.4f, 5.3f, 6.2f, 1.1f, 2.2f, 3.3f, 4.4f,
+ 5.5f, 6.6f, 7.7f, 8.8f, 9.9f, 8.9f, 1.2f, 2.2f };
+
DEFS(f,float)
INITS(f, float)
-TEST(Sf1, float)
-TEST(Sf2, float)
-TEST(Sf3, float)
-TEST(Sf4, float)
-TEST(Sf5, float)
-TEST(Sf6, float)
-TEST(Sf7, float)
-TEST(Sf8, float)
+TEST(f, Sf1, float)
+TEST(f, Sf2, float)
+TEST(f, Sf3, float)
+TEST(f, Sf4, float)
+TEST(f, Sf5, float)
+TEST(f, Sf6, float)
+TEST(f, Sf7, float)
+TEST(f, Sf8, float)
Index: testsuite/gcc.dg/compat/struct-by-value-5b_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-5b_x.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-5b_x.c
--- testsuite/gcc.dg/compat/struct-by-value-5b_x.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-5b_x.c 26 Apr 2004 23:39:07 -0000
@@ -4,17 +4,19 @@
#include "fp-struct-check.h"
#include "fp-struct-test-by-value-x.h"
+extern float fvalues[];
+
DEFS(f, float)
CHECKS(f, float)
-TEST(Sf9, float)
-TEST(Sf10, float)
-TEST(Sf11, float)
-TEST(Sf12, float)
-TEST(Sf13, float)
-TEST(Sf14, float)
-TEST(Sf15, float)
-TEST(Sf16, float)
+TEST(f, Sf9, float)
+TEST(f, Sf10, float)
+TEST(f, Sf11, float)
+TEST(f, Sf12, float)
+TEST(f, Sf13, float)
+TEST(f, Sf14, float)
+TEST(f, Sf15, float)
+TEST(f, Sf16, float)
#undef T
Index: testsuite/gcc.dg/compat/struct-by-value-5b_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-5b_y.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-5b_y.c
--- testsuite/gcc.dg/compat/struct-by-value-5b_y.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-5b_y.c 26 Apr 2004 23:39:07 -0000
@@ -12,14 +12,20 @@ const int test_va = 1;
#include "fp-struct-init.h"
#include "fp-struct-test-by-value-y.h"
+float fvalues[] =
+ { 1.9f, 2.8f, 3.7f, 4.6f, 5.4f, 6.3f, 7.2f, 8.1f,
+ 9.9f, 3.3f, 6.4f, 5.3f, 4.2f, 3.1f, 9.7f, 8.6f,
+ 7.5f, 6.4f, 5.3f, 6.2f, 1.1f, 2.2f, 3.3f, 4.4f,
+ 5.5f, 6.6f, 7.7f, 8.8f, 9.9f, 8.9f, 1.2f, 2.2f };
+
DEFS(f,float)
INITS(f, float)
-TEST(Sf9, float)
-TEST(Sf10, float)
-TEST(Sf11, float)
-TEST(Sf12, float)
-TEST(Sf13, float)
-TEST(Sf14, float)
-TEST(Sf15, float)
-TEST(Sf16, float)
+TEST(f, Sf9, float)
+TEST(f, Sf10, float)
+TEST(f, Sf11, float)
+TEST(f, Sf12, float)
+TEST(f, Sf13, float)
+TEST(f, Sf14, float)
+TEST(f, Sf15, float)
+TEST(f, Sf16, float)
Index: testsuite/gcc.dg/compat/struct-by-value-6a_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-6a_x.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-6a_x.c
--- testsuite/gcc.dg/compat/struct-by-value-6a_x.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-6a_x.c 26 Apr 2004 23:39:07 -0000
@@ -4,17 +4,19 @@
#include "fp-struct-check.h"
#include "fp-struct-test-by-value-x.h"
+extern double dvalues[];
+
DEFS(d, double)
CHECKS(d, double)
-TEST(Sd1, double)
-TEST(Sd2, double)
-TEST(Sd3, double)
-TEST(Sd4, double)
-TEST(Sd5, double)
-TEST(Sd6, double)
-TEST(Sd7, double)
-TEST(Sd8, double)
+TEST(d, Sd1, double)
+TEST(d, Sd2, double)
+TEST(d, Sd3, double)
+TEST(d, Sd4, double)
+TEST(d, Sd5, double)
+TEST(d, Sd6, double)
+TEST(d, Sd7, double)
+TEST(d, Sd8, double)
#undef T
Index: testsuite/gcc.dg/compat/struct-by-value-6a_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-6a_y.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-6a_y.c
--- testsuite/gcc.dg/compat/struct-by-value-6a_y.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-6a_y.c 26 Apr 2004 23:39:07 -0000
@@ -12,14 +12,20 @@ const int test_va = 1;
#include "fp-struct-init.h"
#include "fp-struct-test-by-value-y.h"
+double dvalues[] =
+ { 1.9, 2.8, 3.7, 4.6, 5.4, 6.3, 7.2, 8.1,
+ 9.9, 3.3, 6.4, 5.3, 4.2, 3.1, 9.7, 8.6,
+ 7.5, 6.4, 5.3, 6.2, 1.1, 2.2, 3.3, 4.4,
+ 5.5, 6.6, 7.7, 8.8, 9.9, 8.9, 1.2, 2.2 };
+
DEFS(d, double)
INITS(d, double)
-TEST(Sd1, double)
-TEST(Sd2, double)
-TEST(Sd3, double)
-TEST(Sd4, double)
-TEST(Sd5, double)
-TEST(Sd6, double)
-TEST(Sd7, double)
-TEST(Sd8, double)
+TEST(d, Sd1, double)
+TEST(d, Sd2, double)
+TEST(d, Sd3, double)
+TEST(d, Sd4, double)
+TEST(d, Sd5, double)
+TEST(d, Sd6, double)
+TEST(d, Sd7, double)
+TEST(d, Sd8, double)
Index: testsuite/gcc.dg/compat/struct-by-value-6b_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-6b_x.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-6b_x.c
--- testsuite/gcc.dg/compat/struct-by-value-6b_x.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-6b_x.c 26 Apr 2004 23:39:07 -0000
@@ -4,17 +4,19 @@
#include "fp-struct-check.h"
#include "fp-struct-test-by-value-x.h"
+extern double dvalues[];
+
DEFS(d, double)
CHECKS(d, double)
-TEST(Sd9, double)
-TEST(Sd10, double)
-TEST(Sd11, double)
-TEST(Sd12, double)
-TEST(Sd13, double)
-TEST(Sd14, double)
-TEST(Sd15, double)
-TEST(Sd16, double)
+TEST(d, Sd9, double)
+TEST(d, Sd10, double)
+TEST(d, Sd11, double)
+TEST(d, Sd12, double)
+TEST(d, Sd13, double)
+TEST(d, Sd14, double)
+TEST(d, Sd15, double)
+TEST(d, Sd16, double)
#undef T
Index: testsuite/gcc.dg/compat/struct-by-value-6b_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-6b_y.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-6b_y.c
--- testsuite/gcc.dg/compat/struct-by-value-6b_y.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-6b_y.c 26 Apr 2004 23:39:07 -0000
@@ -12,14 +12,20 @@ const int test_va = 1;
#include "fp-struct-init.h"
#include "fp-struct-test-by-value-y.h"
+double dvalues[] =
+ { 1.9, 2.8, 3.7, 4.6, 5.4, 6.3, 7.2, 8.1,
+ 9.9, 3.3, 6.4, 5.3, 4.2, 3.1, 9.7, 8.6,
+ 7.5, 6.4, 5.3, 6.2, 1.1, 2.2, 3.3, 4.4,
+ 5.5, 6.6, 7.7, 8.8, 9.9, 8.9, 1.2, 2.2 };
+
DEFS(d, double)
INITS(d, double)
-TEST(Sd9, double)
-TEST(Sd10, double)
-TEST(Sd11, double)
-TEST(Sd12, double)
-TEST(Sd13, double)
-TEST(Sd14, double)
-TEST(Sd15, double)
-TEST(Sd16, double)
+TEST(d, Sd9, double)
+TEST(d, Sd10, double)
+TEST(d, Sd11, double)
+TEST(d, Sd12, double)
+TEST(d, Sd13, double)
+TEST(d, Sd14, double)
+TEST(d, Sd15, double)
+TEST(d, Sd16, double)
Index: testsuite/gcc.dg/compat/struct-by-value-7a_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-7a_x.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-7a_x.c
--- testsuite/gcc.dg/compat/struct-by-value-7a_x.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-7a_x.c 26 Apr 2004 23:39:07 -0000
@@ -4,17 +4,19 @@
#include "fp-struct-check.h"
#include "fp-struct-test-by-value-x.h"
+extern long double ldvalues[];
+
DEFS(ld, long double)
CHECKS(ld, long double)
-TEST(Sld1, long double)
-TEST(Sld2, long double)
-TEST(Sld3, long double)
-TEST(Sld4, long double)
-TEST(Sld5, long double)
-TEST(Sld6, long double)
-TEST(Sld7, long double)
-TEST(Sld8, long double)
+TEST(ld, Sld1, long double)
+TEST(ld, Sld2, long double)
+TEST(ld, Sld3, long double)
+TEST(ld, Sld4, long double)
+TEST(ld, Sld5, long double)
+TEST(ld, Sld6, long double)
+TEST(ld, Sld7, long double)
+TEST(ld, Sld8, long double)
#undef T
Index: testsuite/gcc.dg/compat/struct-by-value-7a_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-7a_y.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-7a_y.c
--- testsuite/gcc.dg/compat/struct-by-value-7a_y.c 7 Apr 2004 00:58:29 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-7a_y.c 26 Apr 2004 23:39:07 -0000
@@ -12,14 +12,20 @@ const int test_va = 1;
#include "fp-struct-init.h"
#include "fp-struct-test-by-value-y.h"
+long double ldvalues[] =
+ { 1.9l, 2.8l, 3.7l, 4.6l, 5.4l, 6.3l, 7.2l, 8.1l,
+ 9.9l, 3.3l, 6.4l, 5.3l, 4.2l, 3.1l, 9.7l, 8.6l,
+ 7.5l, 6.4l, 5.3l, 6.2l, 1.1l, 2.2l, 3.3l, 4.4l,
+ 5.5l, 6.6l, 7.7l, 8.8l, 9.9l, 8.9l, 1.2l, 2.2l };
+
DEFS(ld, long double)
INITS(ld, long double)
-TEST(Sld1, long double)
-TEST(Sld2, long double)
-TEST(Sld3, long double)
-TEST(Sld4, long double)
-TEST(Sld5, long double)
-TEST(Sld6, long double)
-TEST(Sld7, long double)
-TEST(Sld8, long double)
+TEST(ld, Sld1, long double)
+TEST(ld, Sld2, long double)
+TEST(ld, Sld3, long double)
+TEST(ld, Sld4, long double)
+TEST(ld, Sld5, long double)
+TEST(ld, Sld6, long double)
+TEST(ld, Sld7, long double)
+TEST(ld, Sld8, long double)
Index: testsuite/gcc.dg/compat/struct-by-value-7b_x.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-7b_x.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-7b_x.c
--- testsuite/gcc.dg/compat/struct-by-value-7b_x.c 7 Apr 2004 00:58:30 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-7b_x.c 26 Apr 2004 23:39:07 -0000
@@ -4,17 +4,19 @@
#include "fp-struct-check.h"
#include "fp-struct-test-by-value-x.h"
+extern long double ldvalues[];
+
DEFS(ld, long double)
CHECKS(ld, long double)
-TEST(Sld9, long double)
-TEST(Sld10, long double)
-TEST(Sld11, long double)
-TEST(Sld12, long double)
-TEST(Sld13, long double)
-TEST(Sld14, long double)
-TEST(Sld15, long double)
-TEST(Sld16, long double)
+TEST(ld, Sld9, long double)
+TEST(ld, Sld10, long double)
+TEST(ld, Sld11, long double)
+TEST(ld, Sld12, long double)
+TEST(ld, Sld13, long double)
+TEST(ld, Sld14, long double)
+TEST(ld, Sld15, long double)
+TEST(ld, Sld16, long double)
#undef T
Index: testsuite/gcc.dg/compat/struct-by-value-7b_y.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/compat/struct-by-value-7b_y.c,v
retrieving revision 1.1
diff -u -p -r1.1 struct-by-value-7b_y.c
--- testsuite/gcc.dg/compat/struct-by-value-7b_y.c 7 Apr 2004 00:58:30 -0000 1.1
+++ testsuite/gcc.dg/compat/struct-by-value-7b_y.c 26 Apr 2004 23:39:07 -0000
@@ -12,14 +12,20 @@ const int test_va = 1;
#include "fp-struct-init.h"
#include "fp-struct-test-by-value-y.h"
+long double ldvalues[] =
+ { 1.9l, 2.8l, 3.7l, 4.6l, 5.4l, 6.3l, 7.2l, 8.1l,
+ 9.9l, 3.3l, 6.4l, 5.3l, 4.2l, 3.1l, 9.7l, 8.6l,
+ 7.5l, 6.4l, 5.3l, 6.2l, 1.1l, 2.2l, 3.3l, 4.4l,
+ 5.5l, 6.6l, 7.7l, 8.8l, 9.9l, 8.9l, 1.2l, 2.2l };
+
DEFS(ld, long double)
INITS(ld, long double)
-TEST(Sld9, long double)
-TEST(Sld10, long double)
-TEST(Sld11, long double)
-TEST(Sld12, long double)
-TEST(Sld13, long double)
-TEST(Sld14, long double)
-TEST(Sld15, long double)
-TEST(Sld16, long double)
+TEST(ld, Sld9, long double)
+TEST(ld, Sld10, long double)
+TEST(ld, Sld11, long double)
+TEST(ld, Sld12, long double)
+TEST(ld, Sld13, long double)
+TEST(ld, Sld14, long double)
+TEST(ld, Sld15, long double)
+TEST(ld, Sld16, long double)