On 12/05/14 12:00, Marek Polacek wrote:
On Fri, Dec 05, 2014 at 12:08:02PM +0100, Jakub Jelinek wrote:
On Fri, Dec 05, 2014 at 11:27:50AM +0100, Marek Polacek wrote:
My recent change to shift operand promotion caused a regression in
loop unrolling.  Fixed as Richi suggested in the PR audit trail.

Bootstrapped/regtested on ppc64-linux and x86_64-linux, ok for trunk?

2014-12-05  Marek Polacek  <pola...@redhat.com>

        PR tree-optimization/64183
        * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
        shift-expression if it is integer_type_node.

        * gcc.dg/tree-ssa/pr64183.c: New test.

This is for middle-end, so I think it would be better to use
the middle-end type equality in the checks, so !types_compatible_p
instead of != ?

Ok, this is a variant with types_compatible_p instead.

Bootstrapped/regtested on ppc64-linux and x86_64-linux.

2014-12-05  Marek Polacek  <pola...@redhat.com>

        PR tree-optimization/64183
        * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
        shift-expression if it is integer_type_node.  Use types_compatible_p.

        * gcc.dg/tree-ssa/pr64183.c: New test.
OK.
jeff

Reply via email to