OSDN Git Service

gcc:
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gcc.target / i386 / vararg-1.c
1 /* PR middle-end/36858 */
2 /* { dg-do run } */
3 /* { dg-options "-w" { target { lp64 } } } */
4 /* { dg-options "-w -msse2 -mpreferred-stack-boundary=2" { target { ilp32 } } } */
5 /* { dg-require-effective-target sse2 } */
6
7 #include "sse2-check.h"
8 #include <stdarg.h>
9 #include <emmintrin.h>
10
11 int
12 __attribute__((noinline))
13 test (int a, ...)
14 {
15   return a;
16 }
17
18 __m128 n1 = { -283.3, -23.3, 213.4, 1119.03 };
19
20 int
21 __attribute__((noinline))
22 foo (void)
23 {
24   return test (1, n1);
25 }
26
27 static void
28 __attribute__((noinline))
29 sse2_test (void)
30 {
31   if (foo () != 1)
32     abort ();
33 }