https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113033
Xi Ruoyao <xry111 at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Component|target |middle-end CC| |jakub at gcc dot gnu.org --- Comment #5 from Xi Ruoyao <xry111 at gcc dot gnu.org> --- It looks like we should do: diff --git a/gcc/expmed.cc b/gcc/expmed.cc index b294eabb08d..b87e09a8a65 100644 --- a/gcc/expmed.cc +++ b/gcc/expmed.cc @@ -2628,9 +2628,7 @@ expand_shift_1 (enum tree_code code, machine_mode mode, rtx shifted, (mode, GET_MODE_BITSIZE (scalar_mode) - INTVAL (op1)); else { - other_amount - = simplify_gen_unary (NEG, GET_MODE (op1), - op1, GET_MODE (op1)); + other_amount = negate_rtx (GET_MODE (op1), op1); HOST_WIDE_INT mask = GET_MODE_PRECISION (scalar_mode) - 1; other_amount = simplify_gen_binary (AND, GET_MODE (op1), other_amount, ??