https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93806
--- Comment #16 from Alexander Cherepanov <ch3root at openwall dot com> --- On 21/02/2020 03.40, vincent-gcc at vinc17 dot net wrote: > Concerning -fno-signed-zeros, your code has undefined behavior since the sign > of zero is significant in "1 / x == 1 / 0.", i.e. changing the sign of 0 > changes the result. If you use this option, you are telling GCC that this > cannot be the case. Thus IMHO, this is not a bug. If I understand correctly what you are saying, then one cannot even do `printf("%f", 0);` because changing the sign of 0 will add a minus in front of 0. This seems kinda restrictive. > I would say that -fno-trapping-math should have no effect because there are no > traps by default (for floating point). With -fno-trapping-math gcc simplifies `1 / x == 1 / 0.` into `1 / x > 1.79769313486231570814527423731704356798070567525844996599e+308`.