Re: [PATCH][combine] Don't create LSHIFTRT of zero bits in change_zero_ext

2015-12-14 Thread Kyrill Tkachov
On 11/12/15 01:26, Segher Boessenkool wrote: On Thu, Dec 10, 2015 at 05:05:12PM +0100, Bernd Schmidt wrote: On 12/10/2015 03:36 PM, Kyrill Tkachov wrote: I'm okay with delaying this for next stage 1 if people prefer, though I think it's pretty low risk. I think this is something we should fix

Re: [PATCH][combine] Don't create LSHIFTRT of zero bits in change_zero_ext

2015-12-10 Thread Segher Boessenkool
On Thu, Dec 10, 2015 at 05:05:12PM +0100, Bernd Schmidt wrote: > On 12/10/2015 03:36 PM, Kyrill Tkachov wrote: > >I'm okay with delaying this for next stage 1 if people prefer, though I > >think it's > >pretty low risk. > > I think this is something we should fix now. I agree. > >+ x = XEXP

Re: [PATCH][combine] Don't create LSHIFTRT of zero bits in change_zero_ext

2015-12-10 Thread Bernd Schmidt
On 12/10/2015 03:36 PM, Kyrill Tkachov wrote: I'm okay with delaying this for next stage 1 if people prefer, though I think it's pretty low risk. I think this is something we should fix now. + x = XEXP (x, 0); + if (start > 0) + x = gen_rtx_LSHIFTRT (mode, x, GEN_INT

[PATCH][combine] Don't create LSHIFTRT of zero bits in change_zero_ext

2015-12-10 Thread Kyrill Tkachov
Hi all, At the end of combine if it fails to recognise the patterns it produces it tries again after transforming all zero_extends and zero_extracts into and-immediate plus an LSHIFTRT if needed. However, it will construct an LSHIFTRT inside the AND even if the shift distance is 0, which can hu