This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix extendsidi2_1 splitting (PR rtl-optimization/57281, PR rtl-optimization/57300 wrong-code, alternative)


On 05/17/2013 01:25 AM, Jakub Jelinek wrote:
> +(define_peephole2
> +  [(set (match_operand:SI 0 "memory_operand")
> +	(match_operand:SI 1 "register_operand"))
> +   (set (match_operand:SI 2 "register_operand") (match_dup 1))
> +   (parallel [(set (match_dup 2)
> +		   (ashiftrt:SI (match_dup 2)
> +				(match_operand:QI 3 "const_int_operand")))
> +	       (clobber (reg:CC FLAGS_REG))])
> +   (set (match_operand:SI 4 "memory_operand") (match_dup 2))]
> +  "INTVAL (operands[3]) == 31

No sense in using match_operand in the pattern and INTVAL == 31
in the condition when you can just use (const_int 31) in the pattern.

Modulo those two cases, the patch is ok.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]