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

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
The ICE is on trying to optimize MINUS of
(unspec:RVVMF32BI [
        (and:RVVMF32BI (const_vector:RVVMF32BI repeat [
                    (const_int 1 [0x1])
                ])
            (reg:RVVMF32BI 147 [ mask__6.8_35 ]))
        (reg:SI 143 [ _41 ])
        (const_int 0 [0])
        (reg:SI 66 vl)
        (reg:SI 67 vtype)
    ] UNSPEC_VPREDICATE)
and
(const_int 0 [0])
with mode E_RVVMF32BImode.
poly_int_rtx_p (op1) is true, so it feels like all the requirements of
neg_poly_int_rtx:
/* Negate I, which satisfies poly_int_rtx_p.  MODE is the mode of I.  */
are met.
      /* Don't let a relocatable value get a negative coeff.  */
      if (poly_int_rtx_p (op1) && GET_MODE (op0) != VOIDmode)
        return simplify_gen_binary (PLUS, mode,
                                    op0,
                                    neg_poly_int_rtx (mode, op1));
But wi::to_poly_wide that neg_poly_int_rtx uses handles vector modes if it is
passed CONST_POLY_INT and for CONST_INT just assumes the mode must be scalar
mode (which is not the case here).

Reply via email to