Fortran: Fix PR 47485.
[gcc.git] / gcc / testsuite / g++.dg / other / i386-1.C
blob108af19e4c832eaab50009bd487b261ccd7182c6
1 /* { dg-do run { target i?86-*-* x86_64-*-* } } */
2 /* { dg-options "-msse2" } */
3 /* { dg-require-effective-target sse2_runtime } */
4 /* { dg-skip-if "requires hosted libstdc++ for cstdlib malloc" { ! hostedlib } } */
6 #include <xmmintrin.h>
8 static void
9 sse2_test (void)
11   float a = 1.0f;
12   float b = 2.0f;
13   float c = 3.0f;
14   float r;
16   __m128 v = _mm_set_ps(a, b, c, 0);
17   
18   v = (__m128)_mm_srli_si128((__m128i)v, 4);
19   _mm_store_ss(&r, v);
20   if (r != 3.0f)
21     abort ();
24 int
25 main ()
27   sse2_test ();
28   return 0;