[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250117102924.690cb7c7@gandalf.local.home>
Date: Fri, 17 Jan 2025 10:29:24 -0500
From: Steven Rostedt <rostedt@...dmis.org>
To: Tomas Glozar <tglozar@...hat.com>
Cc: linux-trace-kernel@...r.kernel.org, linux-kernel@...r.kernel.org, John
Kacur <jkacur@...hat.com>, Luis Goncalves <lgoncalv@...hat.com>, Gabriele
Monaco <gmonaco@...hat.com>
Subject: Re: [PATCH 0/5] rtla/timerlat: Stop on signal properly when
overloaded
On Fri, 17 Jan 2025 13:04:07 +0100
Tomas Glozar <tglozar@...hat.com> wrote:
> I was thinking of turning timerlat_hist_handler/timerlat_top_handler
> into a BPF program and having it executed right after the sample is
> created, e.g. by using the BPF perf interface to hook it to a
> tracepoint event. The histogram/counter would be stored in BPF maps,
> which would be merely copied over in the main loop. This is
> essentially how cyclictest does it, except in userspace. I expect this
> solution to have good performance, but the obvious downside is that it
> requires BPF. This is not a problem for us, but might be for other
> rtla users and we'd likely have to keep both implementations of sample
> processing in the code.
>
> Also, before even starting with that, it would be likely necessary to
> remove the duplicate code throughout timerlat/osnoise and test it
> properly, so we don't have to do the same code changes twice or four
> times.
We could also add kernel helpers to the code if it would help.
Hmm, the timerlat event could probably get access to a trigger to allow it
to do the work in the kernel like what the 'hist' triggers do. We can
extend on that.
The reason I haven't written a BPF program yet, is because when I feel
there's a useful operation that can be done, I just extend ftrace to do it
;-)
-- Steve
Powered by blists - more mailing lists