comparison gcc/testsuite/gcc.dg/torture/pr93946-1.c @ 19:2b5abeee2509 default tip

update gcc11
author anatofuz
date Mon, 25 May 2020 07:50:57 +0900
parents
children
comparison
equal deleted inserted replaced
18:1830386684a0 19:2b5abeee2509
1 /* { dg-do run } */
2
3 union U { long long i; long f; };
4 struct a {union U u;};
5 struct aa {struct a a;};
6 struct b {union U u;};
7 struct bb {struct b b;};
8
9 long __attribute__((noipa))
10 foo (struct bb *bv, void *ptr)
11 {
12 struct aa *a = ptr;
13 struct bb *b = ptr;
14 bv->b.u.f = 1;
15 a->a.u.i = 0;
16 b->b.u.f = 0;
17 return bv->b.u.f;
18 }
19
20 int
21 main ()
22 {
23 union C {struct aa aa; struct bb bb;} v;
24 if (foo (&v.bb, &v) != 0)
25 __builtin_abort ();
26 return 0;
27 }