Re: [Patch combine] Don't create vector mode ZERO_EXTEND from subregs

2017-12-21 Thread James Greenhalgh
On Sun, Dec 17, 2017 at 03:14:08AM +, Segher Boessenkool wrote: > Hi! > > On Mon, Dec 11, 2017 at 02:18:53PM +, James Greenhalgh wrote: > > > > In simplify_set we try transforming the paradoxical subreg expression: > > > > (set FOO (subreg:M (mem:N BAR) 0)) > > > > in to: > > > > (set

Re: [Patch combine] Don't create vector mode ZERO_EXTEND from subregs

2017-12-16 Thread Segher Boessenkool
Hi! On Mon, Dec 11, 2017 at 02:18:53PM +, James Greenhalgh wrote: > > In simplify_set we try transforming the paradoxical subreg expression: > > (set FOO (subreg:M (mem:N BAR) 0)) > > in to: > > (set FOO (zero_extend:M (mem:N BAR))) > > However, this code does not consider the case wh

Re: [Patch combine] Don't create vector mode ZERO_EXTEND from subregs

2017-12-16 Thread Marc Glisse
I was happily going to close PR 55549, but it looks like we are trying the same transformation in a second place in that file :-( On Mon, 11 Dec 2017, James Greenhalgh wrote: Hi, In simplify_set we try transforming the paradoxical subreg expression: (set FOO (subreg:M (mem:N BAR) 0)) in to

Re: [Patch combine] Don't create vector mode ZERO_EXTEND from subregs

2017-12-11 Thread Jeff Law
On 12/11/2017 07:18 AM, James Greenhalgh wrote: > > Hi, > > In simplify_set we try transforming the paradoxical subreg expression: > > (set FOO (subreg:M (mem:N BAR) 0)) > > in to: > > (set FOO (zero_extend:M (mem:N BAR))) > > However, this code does not consider the case where M is a vec

[Patch combine] Don't create vector mode ZERO_EXTEND from subregs

2017-12-11 Thread James Greenhalgh
Hi, In simplify_set we try transforming the paradoxical subreg expression: (set FOO (subreg:M (mem:N BAR) 0)) in to: (set FOO (zero_extend:M (mem:N BAR))) However, this code does not consider the case where M is a vector mode, allowing it to construct (for example): (zero_extend:V4SI (