Re: PR 49145: Another (zero_extend (const_int ...)) in combine

2011-06-05 Thread Eric Botcazou
> PR rtl-optimization/49145 > * combine.c (make_compound_operation): Handle ZERO_EXTEND specially. > > gcc/testsuite/ > PR rtl-optimization/49145 > From Ryan Mansfield > * gcc.c-torture/compile/pr49145.c: New test. OK, thanks. -- Eric Botcazou

Re: PR 49145: Another (zero_extend (const_int ...)) in combine

2011-06-04 Thread Richard Sandiford
Eric Botcazou writes: > SUBREG and ZERO_EXTEND of CONST_INTs are treated somewhat specially in the > entire file, see for example do_SUBST. This isn't the case for other unary > operators, presumably because this isn't really necessary here. So I'm not > convinced that such a generalization i

Re: PR 49145: Another (zero_extend (const_int ...)) in combine

2011-06-01 Thread Eric Botcazou
> I've included the subreg handling as well as the zero_extend handling, > even though make_compound_operation already handles that case correctly. > However, I've cowardly not removed the known_cond subreg handling: > > else if (code == SUBREG) > { > enum machine_mode inner_mode = GET_

PR 49145: Another (zero_extend (const_int ...)) in combine

2011-05-28 Thread Richard Sandiford
Three places in combine.c use SUBST to perform recursive replacements on operands. Two of them (subst and known_cond) handle the special case of a zero_extend operand being optimised to a constant. This patch deals with the third, make_compound_operation. In the PR, make_compound_operation is ab