netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Eric Dumazet <edumazet@google.com>
To: Stefan Wahren <wahrenst@gmx.net>
Cc: Neal Cardwell <ncardwell@google.com>,
	Jakub Kicinski <kuba@kernel.org>,
	 Fabio Estevam <festevam@gmail.com>,
	linux-imx@nxp.com,  Stefan Wahren <stefan.wahren@chargebyte.com>,
	Michael Heimpold <mhei@heimpold.de>,
	netdev@vger.kernel.org,  Yuchung Cheng <ycheng@google.com>
Subject: Re: iperf performance regression since Linux 5.18
Date: Mon, 16 Oct 2023 11:49:47 +0200	[thread overview]
Message-ID: <CANn89i+53WWxaZA5+cc9Yck8h+HTV6BvbybAnvTckriFfKpQMQ@mail.gmail.com> (raw)
In-Reply-To: <a94b00d9-8bbc-4c54-b5c9-4a7902220312@gmx.net>

On Sun, Oct 15, 2023 at 12:23 PM Stefan Wahren <wahrenst@gmx.net> wrote:
>
> Hi,
>
> Am 15.10.23 um 01:26 schrieb Stefan Wahren:
> > Hi Eric,
> >
> > Am 15.10.23 um 00:51 schrieb Eric Dumazet:
> >> On Sat, Oct 14, 2023 at 9:40 PM Neal Cardwell <ncardwell@google.com>
> >> wrote:
> ...
> >> Hmm, we receive ~3200 acks per second, I am not sure the
> >> tcp_tso_should_defer() logic
> >> would hurt ?
> >>
> >> Also the ss binary on the client seems very old, or its output has
> >> been mangled perhaps ?
> > this binary is from Yocto kirkstone:
> >
> > # ss --version
> > ss utility, iproute2-5.17.0
> >
> > This shouldn't be too old. Maybe some missing kernel settings?
> >
> i think i was able to fix the issue by enable the proper kernel
> settings. I rerun initial bad and good case again and overwrote the log
> files:
>
> https://github.com/lategoodbye/tcp_tso_rtt_log_regress/commit/93615c94ba1bf36bd47cc2b91dd44a3f58c601bc

Excellent, thanks.

I see your kernel uses HZ=100, have you tried HZ=1000 by any chance ?

CONFIG_HZ_1000=y
CONFIG_HZ=1000

I see that the bad run seems to be stuck for a while with cwnd=66, but
a smaller amount of packets in flight (26 in following ss extract)

ESTAB 0 315664 192.168.1.12:60542 192.168.1.129:5001
timer:(on,030ms,0) ino:13011 sk:2 <->
skmem:(r0,rb131072,t48488,tb295680,f3696,w319888,o0,bl0,d0) ts sack
cubic wscale:7,6 rto:210 rtt:3.418/1.117 mss:1448 pmtu:1500 rcvmss:536
advmss:1448 cwnd:66 ssthresh:20 bytes_sent:43874400
bytes_acked:43836753 segs_out:30302 segs_in:14110 data_segs_out:30300
send 223681685bps lastsnd:10 lastrcv:4310 pacing_rate 268408200bps
delivery_rate 46336000bps delivered:30275 busy:4310ms unacked:26
rcv_space:14480 rcv_ssthresh:64088 notsent:278016 minrtt:0.744

I wonder if fec pseudo-tso code is adding some kind of artifacts,
maybe with TCP small queue logic.
(TX completion might be delayed too much on fec driver side)

Can you try

ethtool -K eth0 tso off ?

Alternatively I think I mentioned earlier that you could try to reduce
gso_max_size on a 100Mbit link

ip link set dev eth0 gso_max_size 16384

(Presumably a driver could do this tuning automatically)

  reply	other threads:[~2023-10-16  9:50 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-09 18:58 iperf performance regression since Linux 5.18 Stefan Wahren
2023-10-09 19:10 ` Eric Dumazet
2023-10-09 19:19   ` Neal Cardwell
2023-10-13 13:37     ` Stefan Wahren
2023-10-14 19:40       ` Neal Cardwell
2023-10-14 21:16         ` Dave Taht
2023-10-14 22:51         ` Eric Dumazet
2023-10-14 23:24           ` Neal Cardwell
2023-10-14 23:26           ` Stefan Wahren
2023-10-15 10:23             ` Stefan Wahren
2023-10-16  9:49               ` Eric Dumazet [this message]
2023-10-16 10:35                 ` Eric Dumazet
2023-10-16 18:25                   ` Stefan Wahren
2023-10-16 18:47                     ` Eric Dumazet
2023-10-17  9:53                       ` Stefan Wahren
2023-10-17 12:08                         ` Eric Dumazet
2023-10-17 12:17                           ` Stefan Wahren
2023-10-16 18:21                 ` Stefan Wahren
2023-10-15  0:06         ` Stefan Wahren
2023-10-11 12:58   ` Stefan Wahren

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=CANn89i+53WWxaZA5+cc9Yck8h+HTV6BvbybAnvTckriFfKpQMQ@mail.gmail.com \
    --to=edumazet@google.com \
    --cc=festevam@gmail.com \
    --cc=kuba@kernel.org \
    --cc=linux-imx@nxp.com \
    --cc=mhei@heimpold.de \
    --cc=ncardwell@google.com \
    --cc=netdev@vger.kernel.org \
    --cc=stefan.wahren@chargebyte.com \
    --cc=wahrenst@gmx.net \
    --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).