Merged with mainline at revision 128810.
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / xorps.c
blob6803a4d89162096d0bbf239f6fffa1b0b5025730
1 /* { dg-do compile } */
2 /* { dg-options "-Os -msse2" } */
4 typedef float __m128 __attribute__ ((vector_size (16)));
6 static __inline __m128
7 _mm_mul_ps (__m128 __A, __m128 __B)
9 return __builtin_ia32_mulps (__A, __B);
12 static __inline __m128
13 _mm_sub_ps (__m128 __A, __m128 __B)
15 return __builtin_ia32_subps (__A, __B);
18 __m128 POW_FUNC (__m128 x, __m128 y)
20 __m128 xmm0 = x, xmm1 = y, xmm2;
22 xmm0 = __builtin_ia32_xorps (xmm1, xmm1);
24 xmm0 = _mm_mul_ps (xmm0, xmm1);
26 xmm0 = _mm_sub_ps (xmm0, xmm1);
28 xmm0 = _mm_mul_ps (xmm0, xmm1);
30 return xmm0;