Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-21 Thread Stephen Hemminger
On Wed, 21 Mar 2007 20:15:37 +0100 Willy Tarreau <[EMAIL PROTECTED]> wrote: > Hi Stephen, > > On Wed, Mar 21, 2007 at 11:54:19AM -0700, Stephen Hemminger wrote: > > On Tue, 13 Mar 2007 21:50:20 +0100 > > Willy Tarreau <[EMAIL PROTECTED]> wrote: > > [...] ( cut my boring part ) > > > > Here are

Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-21 Thread Willy Tarreau
Hi Stephen, On Wed, Mar 21, 2007 at 11:54:19AM -0700, Stephen Hemminger wrote: > On Tue, 13 Mar 2007 21:50:20 +0100 > Willy Tarreau <[EMAIL PROTECTED]> wrote: [...] ( cut my boring part ) > > Here are the results classed by speed : > > > > /* Sample output on a Pentium-M 600 MHz : > > > > Func

Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-21 Thread Stephen Hemminger
On Tue, 13 Mar 2007 21:50:20 +0100 Willy Tarreau <[EMAIL PROTECTED]> wrote: > Hi Stephen, > > On Mon, Mar 12, 2007 at 02:11:56PM -0700, Stephen Hemminger wrote: > > > Oh BTW, I have a newer version with a first approximation of the > > > cbrt() before the div64_64, which allows us to reduce from

Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-13 Thread Willy Tarreau
Hi Stephen, On Mon, Mar 12, 2007 at 02:11:56PM -0700, Stephen Hemminger wrote: > > Oh BTW, I have a newer version with a first approximation of the > > cbrt() before the div64_64, which allows us to reduce from 3 div64 > > to only 2 div64. This results in a version which is twice as fast > > as th

Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-12 Thread Stephen Hemminger
On Sat, 10 Mar 2007 12:48:26 +0100 Willy Tarreau <[EMAIL PROTECTED]> wrote: > On Wed, Mar 07, 2007 at 07:51:35PM -0800, David Miller wrote: > > From: Stephen Hemminger <[EMAIL PROTECTED]> > > Date: Wed, 07 Mar 2007 19:10:47 -0800 > > > > > David Miller wrote: > > > > What about Willy Tarreau's su

Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-10 Thread Willy Tarreau
On Wed, Mar 07, 2007 at 07:51:35PM -0800, David Miller wrote: > From: Stephen Hemminger <[EMAIL PROTECTED]> > Date: Wed, 07 Mar 2007 19:10:47 -0800 > > > David Miller wrote: > > > What about Willy Tarreau's supposedly even faster variant? > > > Or does this incorporate that set of improvements? >

Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-07 Thread Willy Tarreau
On Wed, Mar 07, 2007 at 07:10:47PM -0800, Stephen Hemminger wrote: > David Miller wrote: > >From: Stephen Hemminger <[EMAIL PROTECTED]> > >Date: Wed, 7 Mar 2007 17:07:31 -0800 > > > > > >>The basic calculation has to be done in 32 bits to avoid > >>doing 64 bit divide by 3. The value x is only 22

Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-07 Thread David Miller
From: Stephen Hemminger <[EMAIL PROTECTED]> Date: Wed, 07 Mar 2007 19:10:47 -0800 > David Miller wrote: > > What about Willy Tarreau's supposedly even faster variant? > > Or does this incorporate that set of improvements? > > > That's what this is: > x = (2 * x + (uint32_t)div64_64(a, (uint

Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-07 Thread Stephen Hemminger
David Miller wrote: From: Stephen Hemminger <[EMAIL PROTECTED]> Date: Wed, 7 Mar 2007 17:07:31 -0800 The basic calculation has to be done in 32 bits to avoid doing 64 bit divide by 3. The value x is only 22bits max so only need full 64 bits only for x^2. Signed-off-by: Stephen Hemminger <[E

Re: [PATCH] tcp_cubic: use 32 bit math

2007-03-07 Thread David Miller
From: Stephen Hemminger <[EMAIL PROTECTED]> Date: Wed, 7 Mar 2007 17:07:31 -0800 > The basic calculation has to be done in 32 bits to avoid > doing 64 bit divide by 3. The value x is only 22bits max > so only need full 64 bits only for x^2. > > Signed-off-by: Stephen Hemminger <[EMAIL PROTECTED]>

[PATCH] tcp_cubic: use 32 bit math

2007-03-07 Thread Stephen Hemminger
The basic calculation has to be done in 32 bits to avoid doing 64 bit divide by 3. The value x is only 22bits max so only need full 64 bits only for x^2. Signed-off-by: Stephen Hemminger <[EMAIL PROTECTED]> --- net/ipv4/tcp_cubic.c |8 1 file changed, 4 insertions(+), 4 deletions(-)