DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Morten Brørup" <mb@smartsharesystems.com>
To: <dev@dpdk.org>
Cc: <honnappa.nagarahalli@arm.com>, <konstantin.v.ananyev@yandex.ru>
Subject: Ring library optimization idea
Date: Sun, 20 Aug 2023 11:23:38 +0200	[thread overview]
Message-ID: <98CBD80474FA8B44BF855DF32C47DC35D87B21@smartserver.smartshare.dk> (raw)

Most of the fast path ring library functions access the two cache lines containing respectively the r->prod and r->cons structures.

Some of the fast path functions also have to fetch r->capacity and r->mask, which reside in another cache line.

What do you think about adding shadow variables of r->capacity and r->mask to the same cache line as r->prod, to improve ring library performance (by avoiding having to read a third cache line) when under CPU cache pressure?

-Morten


             reply	other threads:[~2023-08-20  9:23 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-20  9:23 Morten Brørup [this message]
2023-08-21  4:40 ` Honnappa Nagarahalli
2023-08-21 10:19   ` Konstantin Ananyev

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=98CBD80474FA8B44BF855DF32C47DC35D87B21@smartserver.smartshare.dk \
    --to=mb@smartsharesystems.com \
    --cc=dev@dpdk.org \
    --cc=honnappa.nagarahalli@arm.com \
    --cc=konstantin.v.ananyev@yandex.ru \
    /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).