1 /* Check for Darwin m64 that we do not try to pass & return by value for a
2 struct exceeding the number of arg FPRs (the struct here straddles the
4 /* { dg-do run { target { powerpc*-*-darwin* && lp64 } } } */
6 extern void abort (void);
11 extern int printf (const char *, ...);
12 extern int printf$
LDBL128 (const char *, ...);
15 typedef struct fourteen
{
16 long double a
, b
, c
, d
, e
, f
, g
;
19 fourteen_t
foo (fourteen_t
, fourteen_t
) __attribute__ ((noinline
));
22 foo (fourteen_t aa
, fourteen_t bb
)
40 ("%Lg %Lg %Lg %Lg %Lg %Lg %Lg %Lg %Lg %Lg %Lg %Lg %Lg %Lg: "
41 "%Lg %Lg %Lg %Lg %Lg %Lg %Lg\n",
42 aa
.a
, aa
.b
, aa
.c
, aa
.d
, aa
.e
, aa
.f
, aa
.g
,
43 bb
.a
, bb
.b
, bb
.c
, bb
.d
, bb
.e
, bb
.f
, bb
.g
,
44 r
.a
, r
.b
, r
.c
, r
.d
, r
.e
, r
.f
, r
.g
);
45 printf ("aa.g %ll16x %ll16x\nbb.g %ll16x %ll16x\n",
46 *(unsigned long long*)&aa
.g
,
47 *(unsigned long long*)(((char *)&aa
.g
)+8),
48 *(unsigned long long*)&bb
.g
,
49 *(unsigned long long*)(((char *)&bb
.g
)+8));
53 __asm__ (""); /* double make sure we don't get inlined */
60 fourteen_t x
= { 1.L
, 2.L
, 3.L
, 4.L
, 5.L
, 6.L
,-12.3456789123456789L };
61 fourteen_t y
= { 8.L
, 9.L
, 10.L
, 11.L
, 12.L
, 13.L
, 12.3456789123456789L };
73 (" z: %Lg %Lg %Lg %Lg %Lg %Lg %Lg\n"
74 "ret: %ll16x %ll16x\nzz : %ll16x %ll16x\n",
75 z
.a
, z
.b
, z
.c
, z
.d
, z
.e
, z
.f
, z
.g
,
76 *(unsigned long long*)&z
.g
,
77 *(unsigned long long*)(((char *)&z
.g
)+8),
78 *(unsigned long long*)&zz
,
79 *(unsigned long long*)(((char *)&zz
)+8));
82 /* Yes, we really do want to do an equality test here. */