Require target lra in gcc.dg/pr108095.c
[official-gcc.git] / gcc / testsuite / gcc.dg / pr84877.c
blobd1fb84763c86e5c49d36dc5a5ff22dfd01d0da5c
1 /* { dg-do run { xfail { cris-*-* hppa*-*-* sparc*-*-* } } } */
2 /* { dg-options "-O2" } */
4 #include <inttypes.h>
6 struct U {
7 int M0;
8 int M1;
9 } __attribute ((aligned (16)));
11 volatile struct U p0 = {1, 0};
13 void __attribute__ ((noinline))
14 foo (struct U p)
17 volatile intptr_t mask = 0b1111;
18 volatile int dummy[2];
19 struct U p1 = p;
20 dummy[1] = p.M0;
22 if ((intptr_t)(&p1) & mask)
23 __builtin_abort ();
24 if ((intptr_t)(&p) & mask)
25 __builtin_abort ();
27 if (p1.M0 != dummy[1])
28 __builtin_abort ();
29 if (p1.M1 != p.M1)
30 __builtin_abort ();
33 int
34 main ()
36 foo (p0);
37 return 0;