https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104356

--- Comment #15 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
And in rtlanal.cc, see may_trap_p_1:

      /* Division by a non-constant might trap.  */
    case DIV:
    case MOD:
    case UDIV:
    case UMOD:
      if (HONOR_SNANS (x))
        return 1;
      if (FLOAT_MODE_P (GET_MODE (x)))
        return flag_trapping_math;
      if (!CONSTANT_P (XEXP (x, 1)) || (XEXP (x, 1) == const0_rtx))
        return 1;

Reply via email to