[Bug middle-end/107117] "atan2" fails to set the floating-point inexact exception due to constant folding, in some cases

2022-10-06 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107117

--- Comment #5 from Richard Biener  ---
Btw, we only avoid inexact constant foldings for -frounding-math, not with
-ftrapping-math (which guards FP exception state).  See do_mpfr_ckconv.
So we could do better here if we want (but then if at runtime the inexact
exception is raised is unspecified).

[Bug middle-end/107117] "atan2" fails to set the floating-point inexact exception due to constant folding, in some cases

2022-10-02 Thread schwab--- via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107117

--- Comment #4 from Andreas Schwab  ---
Whether the inexact exception is raised or not is unspecified in general, and
atan2 is no exception.