2014-04-15 Richard Biener <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / recip-vec-sqrtf.c
blob6c0d49b2214fb13c8867fd30874fedcb28c88814
1 /* { dg-do compile } */
2 /* { dg-options "-O2 -ffast-math -ftree-vectorize -msse -mfpmath=sse -mrecip -fno-common" } */
4 float a[4];
5 float b[4];
6 float r[4];
8 extern float sqrtf (float);
10 void t1(void)
12 int i;
14 for (i = 0; i < 4; i++)
15 r[i] = a[i] / sqrtf (b[i]);
18 void t2(void)
20 int i;
22 for (i = 0; i < 4; i++)
23 r[i] = sqrtf (a[i] / b[i]);
26 void t3(void)
28 int i;
30 for (i = 0; i < 4; i++)
31 r[i] = sqrtf (a[i]);
34 /* { dg-final { scan-assembler-times "rsqrtps" 3 } } */