https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78249
Roger Sayle <roger at nextmovesoftware dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |roger at nextmovesoftware dot com Status|NEW |RESOLVED Resolution|--- |DUPLICATE --- Comment #4 from Roger Sayle <roger at nextmovesoftware dot com> --- After a little investigating it turns out that this is a duplicate of PR middle-end/51446. When multiplying 0 * Inf, x86/ia64 chips return -NaN, where other architectures return NaN. Alas IEEE doesn't specify the sign of the NaN, so GCC isn't "wrong", but it's odd that multiplications performed at run-time produce a different result to those computed at compile-time (hence the -O0 vs -O1/2/3 differences). Ideally this should (perhaps) be controlled by a target hook. *** This bug has been marked as a duplicate of bug 51446 ***