Re: [PATCH 00/18] [ANNOUNCE] Dynamically created function based events

Steven Rostedt
2018-02-05T15:07:43Z

On Mon, 5 Feb 2018 14:53:55 +0100
Juri Lelli <juri.lelli@redhat.com> wrote:

> First impression is that this is going to be definitely useful if
>
> - it's possibile to hook at function end (e.g., replenish_dl_entity above
> carries more useful information _after_ it did its job)

The one issue is that you will only have access to one argument at the
end. And that will be the return value. How useful would that be?

Hmm, actually, if we incorporate Tom Zanussi's histogram patches (which
I'll start reviewing this week for inclusion), we could add the pseudo
events to carry necessary data.

> - inside functions? not really sure it's actually going to be needed, but I
> was wondering if it's possible at all :); with tracepoints it's for example
> easy to collect detailed information about which branches has been taken etc.

This will not be something to handle anything other than function
calls. You have three options for dealing with inside a function.

- add another function that can be traced with this, inside the
function

- use kprobes

- add a tracepoint

>
> I'm going to play with this more. Just wanted to give back a quick positive
> feedback.

Thanks!

>
> I'm also adding Arm folks to the discussion, as they (and I :) have been
> asking to add tracepoints to scheduler code in the past [1].

You will need to implement the arch_get_func_args() for ARM too.

-- Steve