From: Nick Alcock <nick.alcock@oracle.com>
To: <eugene.loh@oracle.com>, <dtrace@lists.linux.dev>,
<dtrace-devel@oss.oracle.com>
Subject: Re: [DTrace-devel] [PATCH 1/3] Cache per-CPU agg map IDs
Date: Wed, 16 Jul 2025 14:20:40 +0100 [thread overview]
Message-ID: <87v7nsmfvb.fsf@esperi.org.uk> (raw)
In-Reply-To: <20250501182252.27772-1-eugene.loh@oracle.com> (eugene loh's message of "Thu, 1 May 2025 14:22:50 -0400")
On 1 May 2025, eugene loh outgrape:
> From: Eugene Loh <eugene.loh@oracle.com>
>
> The dt_bpf_map_lookup_fd(dtp->dt_aggmap_fd, &cpu) call that is used to
> snap or truncate aggregations takes a few milliseconds, which seems all
> right. For large systems (e.g., 100 CPUs) and many truncations (e.g.,
> tst.trunc.d, etc.), however, a trunc() might end up costing a minute on
> the consumer side, which is unreasonable and causes such tests to time
> out. The run time is due almost exclusively to looking up the per-CPU
> agg map ID.
... how on earth did you figure this out? Some sort of profiler,
presumably...
> Cache the per-CPU agg map IDs.
LGTM, doing the slow operation only once rather than once per snap seems
sensible. (If this turns out to slow down the no-aggs case too much,
we could always populate the map just once on the first call to
dtrace_aggregate_snap() and dt_aggwalk_remove(). But presumably just one
operation is fast enough.)
> Signed-off-by: Eugene Loh <eugene.loh@oracle.com>
Reviewed-by: Nick Alcock <nick.alcock@oracle.com>
(as long as Kris is happy with this probably-theoretical slowdown.)
--
NULL && (void)
next prev parent reply other threads:[~2025-07-16 13:20 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-01 18:22 [PATCH 1/3] Cache per-CPU agg map IDs eugene.loh
2025-05-01 18:22 ` [PATCH 2/3] test: Convert tick-* probes to ioctl:entry for tst.trunc[quant].d eugene.loh
2025-07-16 13:21 ` Nick Alcock
2025-05-01 18:22 ` [PATCH 3/3] test: Mimic dtrace arithmetic more closely for avg/stddev eugene.loh
2025-07-16 13:22 ` [DTrace-devel] " Nick Alcock
2025-07-16 19:51 ` Eugene Loh
2025-07-16 13:20 ` Nick Alcock [this message]
2025-07-16 18:42 ` [DTrace-devel] [PATCH 1/3] Cache per-CPU agg map IDs Eugene Loh
2025-07-16 19:10 ` Kris Van Hees
2025-07-16 20:05 ` Eugene Loh
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=87v7nsmfvb.fsf@esperi.org.uk \
--to=nick.alcock@oracle.com \
--cc=dtrace-devel@oss.oracle.com \
--cc=dtrace@lists.linux.dev \
--cc=eugene.loh@oracle.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.