https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109386
--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Created attachment 54803 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54803&action=edit gcc13-pr109386.patch Untested fix. When LT/LE/GT/GE have lhs [0, 0] or UNLT/UNLE/UNGT/UNGE have lhs [1, 1], we don't know anything (VARYING) about one operand if the other operand may be a NAN, not just is known to be a NAN, because if it happens to be NAN at runtime, the comparison is false (resp. true) regardless of the finite/infinite comparison results.