Re: [Committed] Fix 54524: Wrong code with some 64bit addition with registers as 32bits

2012-11-05 Thread Eric Botcazou
> Hmm, like you said originally in the PR, I think generating the invalid > PLUS is the bug here. I agree (as Richard B said) that an invalid PLUS > shouldn't cause us to generate wrong code, but an assert seems better > than a check. Eric, what do you think? I think that this boils down to deci

Re: [Committed] Fix 54524: Wrong code with some 64bit addition with registers as 32bits

2012-11-03 Thread Richard Sandiford
Andrew Pinski writes: > Hi, > For some reason cse produced: > (insn 27 43 28 2 (set (reg:SI 231 [+4 ]) > (plus:SI (reg:SI 229 [+4 ]) > (const_int 0 [0]))) t.c:24 10 {*addsi3} > (nil)) > > (insn 28 27 29 2 (set (reg:SI 212) > (ltu:SI (reg:SI 231 [+4 ]) >

[Committed] Fix 54524: Wrong code with some 64bit addition with registers as 32bits

2012-11-02 Thread Andrew Pinski
Hi, For some reason cse produced: (insn 27 43 28 2 (set (reg:SI 231 [+4 ]) (plus:SI (reg:SI 229 [+4 ]) (const_int 0 [0]))) t.c:24 10 {*addsi3} (nil)) (insn 28 27 29 2 (set (reg:SI 212) (ltu:SI (reg:SI 231 [+4 ]) (reg:SI 229 [+4 ]))) t.c:24 521 {*sltu_