* gcc.target/powerpc/recip-sqrtf.c: New test.

From-SVN: r231318
This commit is contained in:
David Edelsohn 2015-12-05 12:55:43 +00:00 committed by David Edelsohn
parent 4f0055bd4e
commit a5bdd742c7
2 changed files with 25 additions and 0 deletions

View file

@ -1,3 +1,7 @@
2015-12-05 David Edelsohn <dje.gcc@gmail.com>
* gcc.target/powerpc/recip-sqrtf.c: New test.
2015-12-04 Aditya Kumar <aditya.k7@samsung.com>
Sebastian Pop <s.pop@samsung.com>

View file

@ -0,0 +1,21 @@
/* { dg-do compile } */
/* { dg-options "-O2 -ffast-math -mcpu=power5 -mrecip" } */
extern float sqrtf (float);
float t1(float a, float b)
{
return a/sqrtf(b);
}
float t2(float a, float b)
{
return sqrtf(a/b);
}
float t3(float a)
{
return sqrtf(a);
}
/* { dg-final { scan-assembler-times "frsqrtes" 3 } } */