1 /* { dg-do compile } */
2 /* { dg-options "-O2 -msse -msse2" } */
4 /* Test that the intrinsics compile with optimization. These were not
5 tested in i386-sse-[12].c because these builtins require immediate
13 __m128 a
= _mm_set1_ps (1.0);
14 __m128 b
= _mm_set1_ps (2.0);
15 return _mm_shuffle_ps (a
, b
, _MM_SHUFFLE (0,1,2,3));
19 test_ins_ext (__m64 a
)
21 return _mm_insert_pi16 (a
, _mm_extract_pi16 (a
, 0), 3);
27 return _mm_shuffle_pi16 (a
, 0xA5);
31 test_prefetch (char *p
)
33 _mm_prefetch (p
, _MM_HINT_T0
);
34 _mm_prefetch (p
+4, _MM_HINT_T1
);
35 _mm_prefetch (p
+8, _MM_HINT_T2
);
36 _mm_prefetch (p
+12, _MM_HINT_NTA
);
40 test__slli_si128 (__m128i a
)
42 return _mm_slli_si128 (a
, 3);
46 test__srli_si128 (__m128i a
)
48 return _mm_srli_si128 (a
, 3);