------- Comment #8 from jakub at gcc dot gnu dot org 2010-09-14 17:15 ------- I've looked at the combiner with the second patch, but I'm afraid this isn't fixable in the combiner easily. While combiner is able for i3 (set (reg:V2DI res) (plus:V2DI (reg:V2DI temp) (mem:V2DI (symbol_ref:P t)))) , i2 (set (reg:V2DI temp) (minus:V2DI zero) (mem:V2DI (reg:V2DI a))) and i1 (set (reg:V2DI zero) (const_vector:V2DI [0 0])) to figure this is (set (reg:V2DI res) (minus:V2DI (mem:V2DI (symbol_ref:P t)) (reg:V2DI a)) (plus repeating i1, as its result is not dead), this pattern doesn't match as minus obviously isn't commutative and combiner doesn't try to make 3 insns out of 3. So I'd prefer if we could either apply the first patch, or try TER on the PLUS_EXPR to see if the second operand isn't negation and expand it as MINUS_EXPR, even when MINUS_EXPR isn't allowed on such arguments in GIMPLE.
-- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45633