From: <yang.yang29@zte.com.cn>
To: <kuba@kernel.org>
Cc: <davem@davemloft.net>, <edumazet@google.com>, <pabeni@redhat.com>,
<bigeasy@linutronix.de>, <imagedong@tencent.com>,
<kuniyu@amazon.com>, <petrm@nvidia.com>, <liu3101@purdue.edu>,
<wujianguo@chinatelecom.cn>, <netdev@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <tedheadster@gmail.com>
Subject: Re: [PATCH linux-next] net: record times of netdev_budget exhausted
Date: Wed, 7 Dec 2022 15:27:22 +0800 (CST) [thread overview]
Message-ID: <202212071527223155626@zte.com.cn> (raw)
In-Reply-To: <20221205184742.0952fc75@kernel.org>
On Tue, 6 Dec 2022 10:47:07 +0800 (CST) kuba@kernel.org wrote:
> But are you seeing actual performance wins in terms of throughput
> or latency?
I did a test and see 7~8% of performance difference with small and big
netdev_budget. Detail:
1. machine
In qemu. CPU is QEMU TCG CPU version 2.5+.
2. kernel
Linux (none) 5.14.0-rc6+ #91 SMP Tue Dec 6 19:55:14 CST 2022 x86_64 GNU/Linux
3. test condition
Run 5 rt tasks to simulate workload, task is test.sh:
---
#!/bin/bash
while [ 1 ]
do
ls > /dev/null
done
---
4. test method
Use ping -f to flood.
# ping -f 192.168.1.201 -w 1800
With netdev_buget is 500, and netdev_budget_usecs is 2000:
497913 packets transmitted, 497779 received, 0% packet loss, time 1799992ms
rtt min/avg/max/mdev = 0.181/114.417/1915.343/246.098 ms, pipe 144, ipg/ewma 3.615/0.273 ms
With netdev_budget is 1, and netdev_budget_usecs is 2000:
457530 packets transmitted, 457528 received, 0% packet loss, time 1799997ms
rtt min/avg/max/mdev = 0.180/123.287/1914.186/253.883 ms, pipe 147, ipg/ewma 3.934/0.301 ms
With small netdev_budget, avg latency increases 7%, packets transmitted
decreases 8%.
> Have you tried threaded NAPI? (find files called 'threaded' in sysfs)
Thanks, we had researched on threaded NAPI, much applaud for it!
But we think someone maynot use it because some kinds of reasons.
One is threaded NAPI is good for control, but maynot good for
throughput, especially for those who not care real-time too much.
Another reason is distribution kernel may too old to support
threaded NAPI?
>Well, we can't be sure if there's really nobody that uses them :(
As we still retain netdev_budget*, and there maybe some using it,
should it be improve? Netdev_budget* are sysctl for administrator,
when administrator adjust them, they may want to see the effect in
a direct or easy way. That's what this patch's purpose.
next prev parent reply other threads:[~2022-12-07 7:27 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-03 8:12 [PATCH linux-next] net: record times of netdev_budget exhausted yang.yang29
2022-12-03 10:06 ` kernel test robot
2022-12-03 16:50 ` kernel test robot
2022-12-03 16:50 ` kernel test robot
2022-12-06 1:53 ` Jakub Kicinski
2022-12-06 2:35 ` yang.yang29
2022-12-06 2:47 ` Jakub Kicinski
2022-12-07 7:27 ` yang.yang29 [this message]
2022-12-07 7:58 ` Eric Dumazet
2022-12-07 8:17 ` yang.yang29
2022-12-07 23:28 ` Jakub Kicinski
2022-12-07 12:30 ` yang.yang29
2022-12-07 23:32 ` Jakub Kicinski
2022-12-08 1:12 ` yang.yang29
2022-12-08 1:23 ` Jakub Kicinski
2022-12-08 1:42 ` yang.yang29
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=202212071527223155626@zte.com.cn \
--to=yang.yang29@zte.com.cn \
--cc=bigeasy@linutronix.de \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=imagedong@tencent.com \
--cc=kuba@kernel.org \
--cc=kuniyu@amazon.com \
--cc=linux-kernel@vger.kernel.org \
--cc=liu3101@purdue.edu \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=petrm@nvidia.com \
--cc=tedheadster@gmail.com \
--cc=wujianguo@chinatelecom.cn \
/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