From: David Miller <davem@davemloft.net>
To: eric.dumazet@gmail.com
Cc: netdev@vger.kernel.org, ncardwell@google.com, ycheng@google.com,
vanj@google.com, therbert@google.com
Subject: Re: [PATCH v3 net-next] tcp: TSO packets automatic sizing
Date: Thu, 29 Aug 2013 15:51:31 -0400 (EDT) [thread overview]
Message-ID: <20130829.155131.1753610025310087003.davem@davemloft.net> (raw)
In-Reply-To: <1377607592.8828.149.camel@edumazet-glaptop>
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Tue, 27 Aug 2013 05:46:32 -0700
> From: Eric Dumazet <edumazet@google.com>
>
> After hearing many people over past years complaining against TSO being
> bursty or even buggy, we are proud to present automatic sizing of TSO
> packets.
>
> One part of the problem is that tcp_tso_should_defer() uses an heuristic
> relying on upcoming ACKS instead of a timer, but more generally, having
> big TSO packets makes little sense for low rates, as it tends to create
> micro bursts on the network, and general consensus is to reduce the
> buffering amount.
>
> This patch introduces a per socket sk_pacing_rate, that approximates
> the current sending rate, and allows us to size the TSO packets so
> that we try to send one packet every ms.
>
> This field could be set by other transports.
>
> Patch has no impact for high speed flows, where having large TSO packets
> makes sense to reach line rate.
>
> For other flows, this helps better packet scheduling and ACK clocking.
>
> This patch increases performance of TCP flows in lossy environments.
>
> A new sysctl (tcp_min_tso_segs) is added, to specify the
> minimal size of a TSO packet (default being 2).
>
> A follow-up patch will provide a new packet scheduler (FQ), using
> sk_pacing_rate as an input to perform optional per flow pacing.
>
> This explains why we chose to set sk_pacing_rate to twice the current
> rate, allowing 'slow start' ramp up.
>
> sk_pacing_rate = 2 * cwnd * mss / srtt
>
> v2: Neal Cardwell reported a suspect deferring of last two segments on
> initial write of 10 MSS, I had to change tcp_tso_should_defer() to take
> into account tp->xmit_size_goal_segs
>
> Signed-off-by: Eric Dumazet <edumazet@google.com>
Applied, please post a new copy of your accompanying packet scheduler.
Thanks.
next prev parent reply other threads:[~2013-08-29 19:51 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-24 0:29 [PATCH net-next] tcp: TSO packets automatic sizing Eric Dumazet
2013-08-24 3:17 ` Neal Cardwell
2013-08-24 18:56 ` Eric Dumazet
2013-08-24 20:28 ` Eric Dumazet
2013-08-25 22:01 ` Yuchung Cheng
2013-08-26 0:37 ` Eric Dumazet
2013-08-26 2:22 ` Eric Dumazet
2013-08-26 3:58 ` Eric Dumazet
2013-08-25 2:46 ` David Miller
2013-08-25 2:52 ` Eric Dumazet
2013-08-26 4:26 ` [PATCH v2 " Eric Dumazet
2013-08-26 19:09 ` Yuchung Cheng
2013-08-26 20:28 ` Eric Dumazet
2013-08-26 22:31 ` Yuchung Cheng
2013-08-27 0:47 ` Eric Dumazet
2013-08-27 12:46 ` [PATCH v3 " Eric Dumazet
2013-08-28 0:17 ` Yuchung Cheng
2013-08-28 0:21 ` Neal Cardwell
2013-08-28 7:37 ` Jason Wang
2013-08-28 10:34 ` Eric Dumazet
2013-08-30 3:02 ` Jason Wang
2013-08-29 19:51 ` David Miller [this message]
2013-08-29 20:26 ` Eric Dumazet
2013-08-29 20:35 ` David Miller
2013-08-29 21:26 ` Eric Dumazet
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130829.155131.1753610025310087003.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=eric.dumazet@gmail.com \
--cc=ncardwell@google.com \
--cc=netdev@vger.kernel.org \
--cc=therbert@google.com \
--cc=vanj@google.com \
--cc=ycheng@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).