annotate gcc/testsuite/gcc.dg/pr41123.c @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 /* PR middle-end/41123 */
kono
parents:
diff changeset
2 /* { dg-do compile } */
kono
parents:
diff changeset
3 /* { dg-options "-O2 -fno-strict-aliasing" } */
kono
parents:
diff changeset
4
kono
parents:
diff changeset
5 struct S { char a, b, c, d, e, f, g, h; };
kono
parents:
diff changeset
6 struct T { int a, b; };
kono
parents:
diff changeset
7
kono
parents:
diff changeset
8 struct S
kono
parents:
diff changeset
9 f1 (float _Complex x)
kono
parents:
diff changeset
10 {
kono
parents:
diff changeset
11 return *(struct S *) & x;
kono
parents:
diff changeset
12 }
kono
parents:
diff changeset
13
kono
parents:
diff changeset
14 int
kono
parents:
diff changeset
15 f2 (float _Complex x)
kono
parents:
diff changeset
16 {
kono
parents:
diff changeset
17 struct S f = f1 (x);
kono
parents:
diff changeset
18 return f.b;
kono
parents:
diff changeset
19 }
kono
parents:
diff changeset
20
kono
parents:
diff changeset
21 struct T
kono
parents:
diff changeset
22 f3 (float _Complex x)
kono
parents:
diff changeset
23 {
kono
parents:
diff changeset
24 return *(struct T *) & x;
kono
parents:
diff changeset
25 }
kono
parents:
diff changeset
26
kono
parents:
diff changeset
27 int
kono
parents:
diff changeset
28 f4 (float _Complex x)
kono
parents:
diff changeset
29 {
kono
parents:
diff changeset
30 struct T f = f3 (x);
kono
parents:
diff changeset
31 return f.a;
kono
parents:
diff changeset
32 }
kono
parents:
diff changeset
33
kono
parents:
diff changeset
34 int
kono
parents:
diff changeset
35 f5 (float _Complex x)
kono
parents:
diff changeset
36 {
kono
parents:
diff changeset
37 struct T f = f3 (x);
kono
parents:
diff changeset
38 return f.b;
kono
parents:
diff changeset
39 }
kono
parents:
diff changeset
40
kono
parents:
diff changeset
41 struct T
kono
parents:
diff changeset
42 f6 (float _Complex x)
kono
parents:
diff changeset
43 {
kono
parents:
diff changeset
44 struct T f = f3 (x);
kono
parents:
diff changeset
45 return f;
kono
parents:
diff changeset
46 }