Merge branches/gcc-4_8-branch rev 210799.
[official-gcc.git] / gcc-4_8-branch / gcc / testsuite / gcc.target / powerpc / recip-1.c
blob59660e35bd532fb496e39f135ef84d1b8bab1bb4
1 /* { dg-do compile { target { { powerpc*-*-* } && { ! powerpc*-apple-darwin* } } } } */
2 /* { dg-require-effective-target powerpc_fprs } */
3 /* { dg-options "-O2 -mrecip -ffast-math -mcpu=power6" } */
4 /* { dg-final { scan-assembler-times "frsqrte" 2 } } */
5 /* { dg-final { scan-assembler-times "fmsub" 2 } } */
6 /* { dg-final { scan-assembler-times "fmul" 6 } } */
7 /* { dg-final { scan-assembler-times "fnmsub" 3 } } */
9 double
10 rsqrt_d (double a)
12 return 1.0 / __builtin_sqrt (a);
15 float
16 rsqrt_f (float a)
18 return 1.0f / __builtin_sqrtf (a);