1 /* PR target/39082 */
2 /* { dg-do compile { target { ! ia32 } } } */
3 /* { dg-options "-O2" } */
4 /* { dg-additional-options "-mabi=sysv" { target x86_64-*-mingw* } } */
5 
6 union un
7 {
8   long double x;
9   int i;
10 };
11 
12 extern int bar1 (union un);
13 extern union un bar2 (int);
14 
15 int
foo1(union un u)16 foo1 (union un u) /* { dg-message "note: the ABI of passing union with long double has changed in GCC 4.4" } */
17 {
18   bar1 (u);
19   return u.i;
20 }
21 
22 int
foo2(void)23 foo2 (void)
24 {
25   union un u;
26   u.i = 1;
27   return foo1 (u) + bar1 (u);
28 }
29 
30 int
foo3(int x)31 foo3 (int x)
32 {
33   union un u = bar2 (x);
34   return u.i;
35 }
36