Add qdf24xx base tuning support.
[official-gcc.git] / gcc / testsuite / gcc.dg / tls / opt-11.c
blobedfe16b7e12eaab7d65ce356599e5097286c324e
1 /* { dg-do run } */
2 /* { dg-require-effective-target tls_runtime } */
3 /* { dg-add-options tls } */
5 __extension__ typedef __SIZE_TYPE__ size_t;
7 extern void abort (void);
8 extern void *memset (void *, int, size_t);
10 struct A
12 char pad[48];
13 int i;
14 int pad2;
15 int j;
17 __thread struct A a;
19 int *
20 __attribute__((noinline))
21 foo (void)
23 return &a.i;
26 int
27 main (void)
29 int *p = foo ();
30 memset (&a, 0, sizeof (a));
31 a.i = 6;
32 a.j = 8;
33 if (p[0] != 6 || p[1] != 0 || p[2] != 8)
34 abort ();
35 return 0;