Re: [PATCH 00/14] xfs: Remove unused trace events
From: Steven Rostedt
Date: Mon Jun 16 2025 - 10:59:09 EST
On Mon, 16 Jun 2025 07:31:19 +0200
Christoph Hellwig <hch@xxxxxx> wrote:
> > I just did an analysis of this:
> >
> > https://lore.kernel.org/lkml/20250613104240.509ff13c@xxxxxxxxxxxxxxxxx/T/#md81abade0df19ba9062fd51ced4458161f885ac3
> >
> > A TRACE_EVENT() is about 5K, and each DEFINE_EVENT() is about 1K.
>
> That's really quite expensive. And you only measured the tezt/data/bss
Yes. This is something I've spent a bit of time over the years trying
to address. With moving a bunch of code into trace_event.c with the
added expense that trace events do function calls.
It looks like it's still growing as the last time I checked it was just
under 5K (something around 4800 bytes) and now it's over 5K, and the
tracepoint code grew 4x. I'll start looking into "why" later when I
have more time to deal with this. My time budget for removing unused
events has pretty much dried up.
> overhead and not even the dynamic memory overhead, which is probably
> a lot more.
Yes, and this is another area I look to make better. It was the
motivation for eventfs which saved over 20 megs of memory by having
trace event files dynamically created instead of being permanent.
-- Steve