Re: Fix PR77881: combine improvement

2016-11-18 Thread Michael Matz
Hi, On Fri, 18 Nov 2016, Bin.Cheng wrote: > On Wed, Nov 16, 2016 at 3:05 PM, Andreas Schwab wrote: > > On Nov 14 2016, Michael Matz wrote: > > > >> PR missed-optimization/77881 > >> * combine.c (simplify_comparison): Remove useless subregs > >> also inside the loop, not just a

Re: Fix PR77881: combine improvement

2016-11-18 Thread Bin.Cheng
On Wed, Nov 16, 2016 at 3:05 PM, Andreas Schwab wrote: > On Nov 14 2016, Michael Matz wrote: > >> PR missed-optimization/77881 >> * combine.c (simplify_comparison): Remove useless subregs >> also inside the loop, not just after it. >> (make_compound_operation): Recognize s

Re: Fix PR77881: combine improvement

2016-11-16 Thread Andreas Schwab
On Nov 14 2016, Michael Matz wrote: > PR missed-optimization/77881 > * combine.c (simplify_comparison): Remove useless subregs > also inside the loop, not just after it. > (make_compound_operation): Recognize some subregs as being > masking as well. This breaks gcc.

Re: Fix PR77881: combine improvement

2016-11-14 Thread Segher Boessenkool
On Mon, Nov 14, 2016 at 05:56:49AM +0100, Michael Matz wrote: > With this patch there are now no regressions on x86-64-linux (bootstrapped > with all languages+ada). Okay for trunk? I build cross-compilers for this for a whole bunch of archs, and built Linux with that, to see what effect this ha

Re: Fix PR77881: combine improvement

2016-11-13 Thread Michael Matz
Hi, On Sat, 12 Nov 2016, Segher Boessenkool wrote: > Hi Michael, > > On Thu, Oct 20, 2016 at 04:20:09PM +0200, Michael Matz wrote: > > PR missed-optimization/77881 > > * combine.c (simplify_comparison): Remove useless subregs > > also inside the loop, not just after it. > > > > test

Re: Fix PR77881: combine improvement

2016-11-12 Thread Segher Boessenkool
Hi Michael, On Thu, Oct 20, 2016 at 04:20:09PM +0200, Michael Matz wrote: > PR missed-optimization/77881 > * combine.c (simplify_comparison): Remove useless subregs > also inside the loop, not just after it. > > testsuite/ > * gcc.target/i386/pr77881.c: New test. This isn

Re: Fix PR77881: combine improvement

2016-10-20 Thread Jeff Law
On 10/20/2016 08:20 AM, Michael Matz wrote: Hello, like analyzed in the PR, combine is able to remove outer subregs that don't do anything interesting in the context they are used (simplify_comparison). But that currently happens outside of the loop that retries simplifications if changes occur

Fix PR77881: combine improvement

2016-10-20 Thread Michael Matz
Hello, like analyzed in the PR, combine is able to remove outer subregs that don't do anything interesting in the context they are used (simplify_comparison). But that currently happens outside of the loop that retries simplifications if changes occurred. When we do that inside the loop as we