Add details output for assume processing.
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / sse2-cvtsd2si-2.c
blob12a673ee4276ede9a17f10de3efc808f49ca0769
1 /* { dg-do run } */
2 /* { dg-options "-O3 -mvsx -Wno-psabi" } */
3 /* { dg-additional-options "-mdejagnu-cpu=power8" { target { ! has_arch_pwr8 } } } */
4 /* { dg-require-effective-target p8vector_hw } */
6 #ifndef CHECK_H
7 #define CHECK_H "sse2-check.h"
8 #endif
10 #include CHECK_H
12 #ifndef TEST
13 #define TEST sse2_test_cvtsd2si_2
14 #endif
16 #include <emmintrin.h>
18 static long long
19 __attribute__((noinline, unused))
20 test (__m128d p)
22 return _mm_cvtsd_si64 (p);
25 static void
26 TEST (void)
28 union128d s;
29 long long e;
30 long long d;
32 s.x = _mm_set_pd (829496729501.4, 429496729501.4);
34 d = test (s.x);
36 e = (long long)(s.a[0] + 0.5);
38 if (d != e)
40 #if DEBUG
41 printf ("sse2_test_cvtsd2si_2; failed\n");
42 printf ("\t [%f,%f] -> [%ld]\n", s.a[0], s.a[1], d);
43 printf ("\t expect [%ld]\n", e);
44 #endif
45 abort ();