Development discussion of WireGuard
 help / color / mirror / Atom feed
From: marcel@linux-ng.de
To: wireguard@lists.zx2c4.com
Subject: Possible performance impact of queuing?
Date: Tue, 13 Sep 2022 19:37:33 +0000	[thread overview]
Message-ID: <46fae16c62151cf55e7b357e8dc0df94@linux-ng.de> (raw)

Hi there,

I was just testing wireguard performance on a new server machine (with lots of cores) and got lower
performance than expected.
However a lot of kernel processes were spawned only using CPUs up to 20% (but not higher).
That got me thinking about a possible cause.

I remembered, that some time ago I noticed a similar behavior for dm-crypt and while investigating
further I found this detailed analysis:
https://blog.cloudflare.com/speeding-up-linux-disk-encryption/
It showed, that the kernel internal queuing has a huge impact on throughput and latency (and
there's a fix/option for that in newer kernel releases, s. end of above blog article (search for
"merged")).

So I wondered if the wireguard code may face the same challenge?
I had a quick look at the code and to me (as a non kernel developer) it looks like it could be
worth a try, to adapt and benchmark the changes made for dm-crypt.

I hope someone with more knowledge about wireguard / kernel internals can comment on that.
(I know wireguard is one of the fastest VPN solutions around, but what if it could be even faster?
:-) )

Bye, Marcel

                 reply	other threads:[~2022-09-28 10:21 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=46fae16c62151cf55e7b357e8dc0df94@linux-ng.de \
    --to=marcel@linux-ng.de \
    --cc=wireguard@lists.zx2c4.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).