From: Anton Gorlov <stalker@altlinux.ru>
To: sisyphus@lists.altlinux.org
Subject: Re: [sisyphus] Обновление ядра std-def до 5.10
Date: Sat, 10 Apr 2021 19:44:58 +0300
Message-ID: <a4ddafab-50b2-389e-fdf6-4840bd9fc86d@altlinux.ru> (raw)
In-Reply-To: <20210409132712.41047a1f@tower>
На 5.x ещё есть жалобы на производительность модуля virtio для сетевых
карт. не так давно обсуждалось в канале разработчиков accel-ppp
Пока склоняются, что сломано вот в этом коммите
====
From: Eric Dumazet <edumazet@google.com>
Xuan Zhuo reported that commit 3226b158e67c ("net: avoid 32 x truesize
under-estimation for tiny skbs") brought a ~10% performance drop.
The reason for the performance drop was that GRO was forced
to chain sk_buff (using skb_shinfo(skb)->frag_list), which
uses more memory but also cause packet consumers to go over
a lot of overhead handling all the tiny skbs.
It turns out that virtio_net page_to_skb() has a wrong strategy :
It allocates skbs with GOOD_COPY_LEN (128) bytes in skb->head, then
copies 128 bytes from the page, before feeding the packet to GRO stack.
This was suboptimal before commit 3226b158e67c ("net: avoid 32 x truesize
under-estimation for tiny skbs") because GRO was using 2 frags per MSS,
meaning we were not packing MSS with 100% efficiency.
Fix is to pull only the ethernet header in page_to_skb()
Then, we change virtio_net_hdr_to_skb() to pull the missing
headers, instead of assuming they were already pulled by callers.
This fixes the performance regression, but could also allow virtio_net
to accept packets with more than 128bytes of headers.
Many thanks to Xuan Zhuo for his report, and his tests/help.
[PATCH net] virtio_net: Do not pull payload in skb->head
prev parent reply other threads:[~2021-04-10 16:44 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-09 10:57 Anton V. Boyarshinov
2021-04-09 11:20 ` Sergey V Turchin
2021-04-09 11:22 ` Антон Мидюков
2021-04-09 18:07 ` Денис Назаров
2021-04-11 19:28 ` Anton V. Boyarshinov
2021-04-11 20:18 ` Денис Назаров
2021-04-12 10:03 ` Anton V. Boyarshinov
2021-04-09 21:37 ` Aleksey Novodvorsky
2021-04-09 12:48 ` Михаил Новоселов
2021-04-09 13:27 ` Anton V. Boyarshinov
2021-04-10 16:44 ` Anton Gorlov [this message]
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=a4ddafab-50b2-389e-fdf6-4840bd9fc86d@altlinux.ru \
--to=stalker@altlinux.ru \
--cc=sisyphus@lists.altlinux.org \
/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
ALT Linux Sisyphus discussions
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/sisyphus/0 sisyphus/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 sisyphus sisyphus/ http://lore.altlinux.org/sisyphus \
sisyphus@altlinux.ru sisyphus@altlinux.org sisyphus@lists.altlinux.org sisyphus@lists.altlinux.ru sisyphus@lists.altlinux.com sisyphus@linuxteam.iplabs.ru sisyphus@list.linux-os.ru
public-inbox-index sisyphus
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.sisyphus
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git