https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103406
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- This is interesting. The trunk does 0.0 for both -O0 and -O1. ICC also does 0.0 for both -O0 and -O1 and -0.0 for -O2. clang does -nan for -O1, -O2 and -O0 MSVC does nan for /O2 and /O1 (7ff8000000000000) and for the non-optimizing case (I think if I read the assembly correctly).