https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98673
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Known to work| |8.4.0
--- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> ---
Please try simplifying the testcase, I've tried
long loadValue;
const long *engLoad;
float engLoadDelta1;
void foo()
{
long i1, numXEntries = 50;
for( i1 = 0 ; i1 < ( numXEntries - 1 ) ; i1++ )
{
if( ( loadValue < engLoad[i1+1] ) && ( loadValue >= engLoad[i1] ) )
{
break ;
}
}
if( i1 == ( numXEntries - 1 ) )
{
loadValue = engLoad[i1] ;
}
engLoadDelta1 = (float)( loadValue - engLoad[i1] ) /
(float)( engLoad[i1 + 1] - engLoad[i1] ) ;
}
which on x86 doesn't exhibit the issue (same code with GCC 8 and GCC 10).