1 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
2 /* { dg-options "-O2 -msse2 -march=athlon" } */
3 /* { dg-final { scan-assembler "pand.*\[bs\]p" } } */
4 /* { dg-final { scan-assembler "pandn.*\[bs\]p" } } */
5 /* { dg-final { scan-assembler "pxor.*\[bs\]p" } } */
6 /* { dg-final { scan-assembler "por.*\[bs\]p" } } */
7 /* { dg-final { scan-assembler "movdqa" } } */
8 /* { dg-final { scan-assembler-not "movaps.*\[bs\]p" } } */
10 /* Verify that we generate proper instruction with memory operand. */
12 #include <xmmintrin.h>
14 t1(__m128i a
, __m128i b
)
16 return _mm_and_si128 (a
,b
);
19 t2(__m128i a
, __m128i b
)
21 return _mm_andnot_si128 (a
,b
);
24 t3(__m128i a
, __m128i b
)
26 return _mm_or_si128 (a
,b
);
29 t4(__m128i a
, __m128i b
)
31 return _mm_xor_si128 (a
,b
);