[Bug middle-end/85524] Strange cbrt() result on linux in C
pinskia at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Apr 25 18:01:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85524
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Component|c |middle-end
Resolution|--- |INVALID
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
This is 1ulp difference. This is a standard issue with floating point; please
read "what every computer scientist should know about floating-point
arithmetic". The first case is the result from libm (which in Linux case comes
from glibc project) and in the second case, GCC constants folds the cbrt and
gets an exact result.
More information about the Gcc-bugs
mailing list