https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65757
--- Comment #8 from dhbbugs <bugs at dhbailey dot com> --- Jerry DeLisl'e output is certainly not correct -- anint should invariably return the nearest whole number. It should be the equivalent of this code: if (x >= 0.0) then anint = aint (x + 0.5) else anint = aint (x - 0.5) endif Here aint is the truncated whole number function (a Fortran intrinsic).