This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [Patch] Bfin: Ensure rotrsi and rotlsi don't accept non-const INTVALS
> (rotate:SI (match_operand:SI 1 "register_operand" "")
> - (match_operand:SI 2 "immediate_operand" "")))]
> + (match_operand:SI 2 "const_int_operand" "")))]
> ""
> {
> - if (INTVAL (operands[2]) != 16)
> + if (GET_CODE (operands[2]) != CONST_INT || INTVAL (operands[2]) != 16)
> FAIL;
The point was, that you'd not need the CONST_INT check anymore,
because it's handled by the predicate.
r~