Small ChangeLog tweak.
[official-gcc.git] / gcc / testsuite / gcc.dg / pr54921.c
blob897877aa00ddb9b67aaab16aaeb70d2477918c10
1 /* PR rtl-optimization/54921 */
2 /* { dg-do run } */
3 /* { dg-options "-Os -fno-omit-frame-pointer -fsched2-use-superblocks -ftree-slp-vectorize" } */
4 /* { dg-additional-options "-fstack-protector" { target fstack_protector } } */
6 struct A
8 int a;
9 char b[32];
10 } a, b;
12 __attribute__((noinline, noclone))
13 struct A
14 bar (int x)
16 struct A r;
17 static int n;
18 r.a = ++n;
19 __builtin_memset (r.b, 0, sizeof (r.b));
20 r.b[0] = x;
21 return r;
24 int
25 main ()
27 a = bar (3);
28 b = bar (4);
29 if (a.a != 1 || a.b[0] != 3 || b.a != 2 || b.b[0] != 4)
30 __builtin_abort ();
31 return 0;