Debian Codegraph @

gcc/testsuite/gcc.target/powerpc/sse-movss-2.c

raw
1 /* { dg-do run } */
2 /* { dg-options "-O3 -mvsx" } */
3 /* { dg-additional-options "-mdejagnu-cpu=power8" { target { ! has_arch_pwr8 } } } */
4 /* { dg-require-effective-target p8vector_hw } */
5
6 #define NO_WARN_X86_INTRINSICS 1
7
8 #ifndef CHECK_H
9 #define CHECK_H "sse-check.h"
10 #endif
11
12 #include CHECK_H
13
14 #ifndef TEST
15 #define TEST sse_test_movss_2
16 #endif
17
18 #include <xmmintrin.h>
19
20 static void
21 __attribute__((noinline, unused))
22 test (float *e, __m128 a)
23 {
24 __asm("" : "+v"(a));
25 return _mm_store_ss (e, a);
26 }
27
28 static void
29 TEST (void)
30 {
31 union128 u;
32 float d[1];
33 float e[1];
34
35 u.x = _mm_set_ps (2134.3343,1234.635654, 1.2234, 876.8976);
36
37 test (d, u.x);
38
39 e[0] = u.a[0];
40
41 if (checkVf (d, e, 1))
42 abort ();
43 }