Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-08-28 Thread Jan Hubicka
> > I am giving the patch brief benchmarking on profiledbootstrap and it it > > won't > > cause major regression, I think we should go ahead with the patch. Uhm, I profiledbootstrapped and we bit too fast to get resonable oprofile. What I get is: 7443 9.4372 lto1 lto1

Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-08-28 Thread Richard Biener
On Wed, Aug 28, 2013 at 2:13 PM, Jan Hubicka wrote: >> On Tue, Aug 27, 2013 at 2:50 PM, Jan Hubicka wrote: >> >> >> >> >> >> I've updated the patch (as attached) to use sreal to compute badness. >> >> + badness = ((int)((double) edge->count / max_count >> >> + * relbenefit / RELAT

Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-08-28 Thread Jan Hubicka
> On Tue, Aug 27, 2013 at 2:50 PM, Jan Hubicka wrote: > >> >> > >> >> I've updated the patch (as attached) to use sreal to compute badness. > >> + badness = ((int)((double) edge->count / max_count > >> + * relbenefit / RELATIVE_TIME_BENEFIT_RANGE * INT_MIN / 2)) / > >> growth

Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-08-28 Thread Richard Biener
On Tue, Aug 27, 2013 at 2:50 PM, Jan Hubicka wrote: >> >> >> >> I've updated the patch (as attached) to use sreal to compute badness. >> + badness = ((int)((double) edge->count / max_count >> + * relbenefit / RELATIVE_TIME_BENEFIT_RANGE * INT_MIN / 2)) / growth; >> + >> >>> >>

Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-08-27 Thread Jan Hubicka
> >> > >> I've updated the patch (as attached) to use sreal to compute badness. > + badness = ((int)((double) edge->count / max_count > + * relbenefit / RELATIVE_TIME_BENEFIT_RANGE * INT_MIN / 2)) / growth; > + > >>> > >>> FP operations on the host are frowned upon if code gene

Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-08-27 Thread Richard Biener
On Tue, Jun 25, 2013 at 12:45 AM, Dehao Chen wrote: > The original patch has some flaw. The new patch is attached. > Bootstrapped and passed regression tests. Ok. Thanks, Richard. > Thanks, > Dehao > > On Mon, Jun 24, 2013 at 9:44 AM, Dehao Chen wrote: >> Hi, Richard, >> >> I've updated the pa

Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-08-19 Thread Dehao Chen
Hi, Richard, Could you take a second look at this patch? Thanks, Dehao On Mon, Jun 24, 2013 at 3:45 PM, Dehao Chen wrote: > The original patch has some flaw. The new patch is attached. > Bootstrapped and passed regression tests. > > Thanks, > Dehao > > On Mon, Jun 24, 2013 at 9:44 AM, Dehao Che

Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-06-24 Thread Dehao Chen
The original patch has some flaw. The new patch is attached. Bootstrapped and passed regression tests. Thanks, Dehao On Mon, Jun 24, 2013 at 9:44 AM, Dehao Chen wrote: > Hi, Richard, > > I've updated the patch (as attached) to use sreal to compute badness. > > Thanks, > Dehao > > On Mon, Jun 24,

Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-06-24 Thread Dehao Chen
Hi, Richard, I've updated the patch (as attached) to use sreal to compute badness. Thanks, Dehao On Mon, Jun 24, 2013 at 5:41 AM, Richard Biener wrote: > On Sat, Jun 22, 2013 at 2:59 AM, Dehao Chen wrote: >> This patch prevents integer-underflow of badness computation in ipa-inline. >> >> Boot

Re: [PATCH] Change the badness computation to ensure no integer-underflow

2013-06-24 Thread Richard Biener
On Sat, Jun 22, 2013 at 2:59 AM, Dehao Chen wrote: > This patch prevents integer-underflow of badness computation in ipa-inline. > > Bootstrapped and passed regression tests. > > OK for trunk? > > Thanks, > Dehao > > gcc/ChangeLog: > 2013-06-21 Dehao Chen > > * ipa-inline.c (edge_badnes

[PATCH] Change the badness computation to ensure no integer-underflow

2013-06-21 Thread Dehao Chen
This patch prevents integer-underflow of badness computation in ipa-inline. Bootstrapped and passed regression tests. OK for trunk? Thanks, Dehao gcc/ChangeLog: 2013-06-21 Dehao Chen * ipa-inline.c (edge_badness): Fix integer underflow. Index: gcc/ipa-inline.c =