XDP-Newbies Archive mirror
 help / color / mirror / Atom feed
From: "Mostafa, Jalal (IPE)" <jalal.mostafa@kit.edu>
To: <xdp-newbies@vger.kernel.org>
Subject: AF_XDP-example/txonly: strange performance with different packet sizes
Date: Wed, 26 Oct 2022 12:34:12 +0200	[thread overview]
Message-ID: <7779608e-0207-a4dd-0979-90ef4ac46e86@kit.edu> (raw)

Hi,

I am running the txonly microbenchmark from the AF_XDP-example sample 
program
in bpf-examples. Howerver, I noticed strange performance with different 
tx packet sizes.

With the following command I generate the below results:

./xdpsock -i enp2s0np0 -q 4 -t -b 2048 -m -s 128 -m

Driver: mlx5 on 40Gbps ConnectX-6
Kernel version: 6.0.0-rc6+

| Pkt Size | Native-ZC PPS | Native-C PPS | Generic PPS  |
| ----------- | -------------------- | ------------------ | 
----------------- |
| 64         | 16.5M              | 1.73M            | 1.71M          |
| 128       | 9.42M              | 1.72M            | 1.66M    |
| 256       | 7.78M              | 1.64M            | 1.66M          |
| 512       | 9.39M              | 1.62M            | 1.59M          |
| 1024     | 4.78M              | 1.42M            | 1.38M    |

At size 128B, I expect 16.5M packets (the limiting performance of 
AF_XDP) since
the link is not saturated. The problem is more obvious at size 256B, 
only 7.78B
even though it jumps again to 9.39M at 512. So I think the problem is 
related to
the packet size and not to a limited performance in the xsk engine in 
the kernel.
Or what do you think?

I have already opened an issue on github here:

https://github.com/xdp-project/bpf-examples/issues/61

Best,
Jalal


             reply	other threads:[~2022-10-26 10:47 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-26 10:34 Mostafa, Jalal (IPE) [this message]
2022-10-31 22:40 ` AF_XDP-example/txonly: strange performance with different packet sizes Mostafa, Jalal (IPE)

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=7779608e-0207-a4dd-0979-90ef4ac46e86@kit.edu \
    --to=jalal.mostafa@kit.edu \
    --cc=xdp-newbies@vger.kernel.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
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 read-only IMAP folder(s) and NNTP newsgroup(s).