libcpp, c, middle-end: Optimize initializers using #embed in C
[official-gcc.git] / gcc / testsuite / gcc.dg / torture / pr65270-1.c
blob8874607f245630f1fc2a458c90c1a301985651a1
1 /* { dg-do run } */
2 /* { dg-options "-fno-common" { target hppa*-*-hpux* } } */
4 struct a
6 int a[100];
7 };
8 typedef struct a misaligned_t __attribute__ ((aligned (8)));
9 typedef struct a aligned_t __attribute__ ((aligned (32)));
11 __attribute__ ((used))
12 __attribute__ ((noinline))
13 void
14 t(void *a, int misaligned, aligned_t *d)
16 int i,v;
17 for (i=0;i<100;i++)
19 if (misaligned)
20 v=((misaligned_t *)a)->a[i];
21 else
22 v=((aligned_t *)a)->a[i];
23 d->a[i]+=v;
26 struct b {int v; misaligned_t m;aligned_t aa;} b;
27 aligned_t d;
28 int
29 main()
31 t(&b.m, 1, &d);
32 return 0;