[Bug c/47892] Fails to vectorize comparison code, if-conversion fails
rguenth at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri Feb 25 10:37:00 GMT 2011
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47892
--- Comment #3 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-02-25 10:24:21 UTC ---
Testcase:
#define PIO6 0.523598776f
#define SA5 2.74201854577e-06f
#define SA4 -1.98410347969e-04f
#define SA3 8.33333320429e-03f
#define SA2 -1.66666666666e-01f
void bestseries9(float * __restrict__ arr,int len)
{
int i;
for(i=0; i<len; i++)
{
float or=arr[i];
float orig=or / 3*(or>PIO6);
float sqr=orig*orig;
arr[i]=orig*(1+sqr*(SA2+sqr*(SA3+sqr*(SA4+SA5*sqr))));
arr[i]=arr[i]*(1+(or>PIO6)*(2-4*arr[i]*arr[i]));
}
}
More information about the Gcc-bugs
mailing list