Merge from mainline (gomp-merge-2005-02-26).
[official-gcc.git] / gcc / testsuite / gcc.dg / mips-rsqrt-2.c
bloba4cddcd0a0d8a3608c1a0b23bb7ce17ecc98d8b0
1 /* { dg-do compile { target "mips*-*-*" } } */
2 /* { dg-options "-O2 -ffast-math -mips4" } */
3 /* { dg-final { scan-assembler "rsqrt.d" } } */
4 /* { dg-final { scan-assembler "rsqrt.s" } } */
6 #if (__mips != 4 && __mips != 64) || __mips_soft_float
7 asm ("# rsqrt.d rsqrt.s");
8 #else
9 extern double sqrt(double);
10 extern float sqrtf(float);
12 double foo(double x)
14 return sqrt(1.0/x);
17 float bar(float x)
19 return sqrtf(1.0f/x);
21 #endif