From: "Morten Brørup" <mb@smartsharesystems.com>
To: thomas@monjalon.net, david.marchand@redhat.com,
olivier.matz@6wind.com, andrew.rybchenko@oktetlabs.ru,
bruce.richardson@intel.com, mattias.ronnblom@ericsson.com
Cc: honnappa.nagarahalli@arm.com, konstantin.v.ananyev@yandex.ru,
dev@dpdk.org, "Morten Brørup" <mb@smartsharesystems.com>
Subject: [PATCH] mempool: add cache guard to per-lcore debug statistics
Date: Mon, 4 Sep 2023 11:10:20 +0200 [thread overview]
Message-ID: <20230904091020.12481-1-mb@smartsharesystems.com> (raw)
The per-lcore debug statistics, if enabled, are frequently written by
their individual lcores, so add a cache guard to prevent CPU cache
thrashing.
Depends-on: series-29415 ("clarify purpose of empty cache lines")
Signed-off-by: Morten Brørup <mb@smartsharesystems.com>
---
lib/mempool/rte_mempool.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/mempool/rte_mempool.h b/lib/mempool/rte_mempool.h
index a05b25d5b9..f70bf36080 100644
--- a/lib/mempool/rte_mempool.h
+++ b/lib/mempool/rte_mempool.h
@@ -78,6 +78,7 @@ struct rte_mempool_debug_stats {
uint64_t get_fail_objs; /**< Objects that failed to be allocated. */
uint64_t get_success_blks; /**< Successful allocation number of contiguous blocks. */
uint64_t get_fail_blks; /**< Failed allocation number of contiguous blocks. */
+ RTE_CACHE_GUARD;
} __rte_cache_aligned;
#endif
--
2.17.1
next reply other threads:[~2023-09-04 9:10 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-04 9:10 Morten Brørup [this message]
2023-09-29 18:32 ` Morten Brørup
2023-09-30 6:24 ` Andrew Rybchenko
2023-10-11 21:28 ` Thomas Monjalon
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=20230904091020.12481-1-mb@smartsharesystems.com \
--to=mb@smartsharesystems.com \
--cc=andrew.rybchenko@oktetlabs.ru \
--cc=bruce.richardson@intel.com \
--cc=david.marchand@redhat.com \
--cc=dev@dpdk.org \
--cc=honnappa.nagarahalli@arm.com \
--cc=konstantin.v.ananyev@yandex.ru \
--cc=mattias.ronnblom@ericsson.com \
--cc=olivier.matz@6wind.com \
--cc=thomas@monjalon.net \
/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).