On x86, GCC 8 r254052 caused: FAIL: math/test-double-y0 FAIL: math/test-double-y1 FAIL: math/test-double-yn FAIL: math/test-float-y0 FAIL: math/test-float-y1 FAIL: math/test-float-yn FAIL: math/test-ldouble-y0 FAIL: math/test-ldouble-y1 in glibc testsuite. The failure looks like: testing double (without inline functions) Failure: y0 (qNaN): Exception "Invalid operation" set Failure: y0 (-qNaN): Exception "Invalid operation" set Failure: y0_downward (qNaN): Exception "Invalid operation" set Failure: y0_downward (-qNaN): Exception "Invalid operation" set Failure: y0_towardzero (qNaN): Exception "Invalid operation" set Failure: y0_towardzero (-qNaN): Exception "Invalid operation" set Failure: y0_upward (qNaN): Exception "Invalid operation" set Failure: y0_upward (-qNaN): Exception "Invalid operation" set
It miscompiled: double __y0 (double x) { if (__builtin_expect (islessequal (x, 0.0) || isgreater (x, X_TLOSS), 0) && _LIB_VERSION != _IEEE_) { if (x < 0.0) { /* d = zero/(x-x) */ __feraiseexcept (FE_INVALID); return __kernel_standard (x, x, 9); } else if (x == 0.0) { /* d = -one/(x-x) */ __feraiseexcept (FE_DIVBYZERO); return __kernel_standard (x, x, 8); } else if (_LIB_VERSION != _POSIX_) /* y0(x>X_TLOSS) */ return __kernel_standard (x, x, 35); } return __ieee754_y0 (x); } Good: 0x00007ffff7a57140 <+0>: pxor %xmm1,%xmm1 0x00007ffff7a57144 <+4>: ucomisd %xmm0,%xmm1 mxcsr 0x1f82 [ DE IM DM ZM OM UM PM ] Bad: 0x00007ffff7a55624 <+4>: pxor %xmm1,%xmm1 0x00007ffff7a55628 <+8>: comisd %xmm0,%xmm1 mxcsr 0x1f83 [ IE DE IM DM ZM OM UM PM ] ^^ This is set.
This may be caused by r253986.
Dup. *** This bug has been marked as a duplicate of bug 82692 ***