Re: Gimpel lowering question.

2018-11-30 Thread Michael Eager
On 11/29/18 10:28, Michael Eager wrote: On 11/28/18 14:37, Andrew Pinski wrote: On Wed, Nov 28, 2018 at 9:47 AM Michael Eager wrote: On 11/28/18 09:10, Jeff Law wrote: On 11/28/18 10:00 AM, Michael Eager wrote: I have a small test case which generates poor quality code on my target. Here i

Re: Gimpel lowering question.

2018-11-30 Thread Jeff Law
On 11/30/18 9:14 AM, Jakub Jelinek wrote: > On Fri, Nov 30, 2018 at 09:08:34AM -0700, Jeff Law wrote: >>> Sth I don't like very much... maybe we can revisit removing >>> the few cases in fold-const.c (thus GENERIC folding) and rely >>> on later GIMPLE passes instead plus on RTL expansion to >>> do

Re: Gimpel lowering question.

2018-11-30 Thread Jakub Jelinek
On Fri, Nov 30, 2018 at 09:08:34AM -0700, Jeff Law wrote: > > Sth I don't like very much... maybe we can revisit removing > > the few cases in fold-const.c (thus GENERIC folding) and rely > > on later GIMPLE passes instead plus on RTL expansion to > > do the reverse transform. > > > > Not for GCC

Re: Gimpel lowering question.

2018-11-30 Thread Jeff Law
On 11/30/18 12:39 AM, Richard Biener wrote: > On Wed, Nov 28, 2018 at 6:10 PM Jeff Law wrote: >> >> On 11/28/18 10:00 AM, Michael Eager wrote: >>> I have a small test case which generates poor quality code on my target. >>> Here is the original: >>> >>> if (cond1 == 2048 || cond2 == 8) >>> {

Re: Gimpel lowering question.

2018-11-29 Thread Richard Biener
On Wed, Nov 28, 2018 at 6:10 PM Jeff Law wrote: > > On 11/28/18 10:00 AM, Michael Eager wrote: > > I have a small test case which generates poor quality code on my target. > > Here is the original: > > > > if (cond1 == 2048 || cond2 == 8) > > { > > x = x + y; > > } > > return x;

Re: Gimpel lowering question.

2018-11-29 Thread Michael Eager
On 11/28/18 14:37, Andrew Pinski wrote: On Wed, Nov 28, 2018 at 9:47 AM Michael Eager wrote: On 11/28/18 09:10, Jeff Law wrote: On 11/28/18 10:00 AM, Michael Eager wrote: I have a small test case which generates poor quality code on my target. Here is the original: if (cond1 == 2048 ||

Re: Gimpel lowering question.

2018-11-28 Thread Andrew Pinski
On Wed, Nov 28, 2018 at 9:47 AM Michael Eager wrote: > > On 11/28/18 09:10, Jeff Law wrote: > > On 11/28/18 10:00 AM, Michael Eager wrote: > >> I have a small test case which generates poor quality code on my target. > >> Here is the original: > >> > >>if (cond1 == 2048 || cond2 == 8) > >>

Re: Gimpel lowering question.

2018-11-28 Thread Jeff Law
On 11/28/18 10:47 AM, Michael Eager wrote: > On 11/28/18 09:10, Jeff Law wrote: >> On 11/28/18 10:00 AM, Michael Eager wrote: >>> I have a small test case which generates poor quality code on my target. >>> Here is the original: >>> >>>    if (cond1 == 2048 || cond2 == 8) >>> { >>>    x =

Re: Gimpel lowering question.

2018-11-28 Thread Michael Eager
On 11/28/18 09:10, Jeff Law wrote: On 11/28/18 10:00 AM, Michael Eager wrote: I have a small test case which generates poor quality code on my target. Here is the original:   if (cond1 == 2048 || cond2 == 8)     {   x = x + y;     }   return x; This ends up generating a series of inst

Re: Gimpel lowering question.

2018-11-28 Thread Jeff Law
On 11/28/18 10:00 AM, Michael Eager wrote: > I have a small test case which generates poor quality code on my target. > Here is the original: > >   if (cond1 == 2048 || cond2 == 8) >     { >   x = x + y; >     } >   return x; > > This ends up generating a series of instructions to compute a f

Gimpel lowering question.

2018-11-28 Thread Michael Eager
I have a small test case which generates poor quality code on my target. Here is the original: if (cond1 == 2048 || cond2 == 8) { x = x + y; } return x; This ends up generating a series of instructions to compute a flag with the result of the condition followed by a single comp