1 /* { dg-do compile } */
2 /* { dg-options "-O2 -msse2 -march=k8" } */
3 /* { dg-final { scan-assembler "andps" } } */
4 /* { dg-final { scan-assembler "andnps" } } */
5 /* { dg-final { scan-assembler "xorps" } } */
6 /* { dg-final { scan-assembler "orps" } } */
7 
8 /* Verify that we generate proper instruction without memory operand.  */
9 
10 #include <xmmintrin.h>
11 __m128
t1(__m128 a,__m128 b)12 t1(__m128 a, __m128 b)
13 {
14 a=_mm_sqrt_ps(a);
15 b=_mm_sqrt_ps(b);
16 return _mm_and_ps (a,b);
17 }
18 __m128
t2(__m128 a,__m128 b)19 t2(__m128 a, __m128 b)
20 {
21 a=_mm_sqrt_ps(a);
22 b=_mm_sqrt_ps(b);
23 return _mm_andnot_ps (a,b);
24 }
25 __m128
t3(__m128 a,__m128 b)26 t3(__m128 a, __m128 b)
27 {
28 a=_mm_sqrt_ps(a);
29 b=_mm_sqrt_ps(b);
30 return _mm_or_ps (a,b);
31 }
32 __m128
t4(__m128 a,__m128 b)33 t4(__m128 a, __m128 b)
34 {
35 a=_mm_sqrt_ps(a);
36 b=_mm_sqrt_ps(b);
37 return _mm_xor_ps (a,b);
38 }
39