Messages in this thread | | | From | Namhyung Kim <> | Date | Thu, 2 Jun 2022 13:06:34 -0700 | Subject | Re: [PATCH 2/5] perf lock: Add lock contention tracepoints record support |
| |
Hi Ian,
On Wed, Jun 1, 2022 at 11:21 PM Ian Rogers <irogers@google.com> wrote: > > On Tue, May 31, 2022 at 11:58 PM Namhyung Kim <namhyung@kernel.org> wrote: > > > > When LOCKDEP and LOCK_STAT events are not available, it falls back to > > record the new lock contention tracepoints. > > > > Signed-off-by: Namhyung Kim <namhyung@kernel.org> > > --- > > tools/perf/builtin-lock.c | 70 +++++++++++++++++++++++++++++++++++---- > > 1 file changed, 63 insertions(+), 7 deletions(-) > > > > diff --git a/tools/perf/builtin-lock.c b/tools/perf/builtin-lock.c > > index 23a33ac15e68..3e3320b8cede 100644 > > --- a/tools/perf/builtin-lock.c > > +++ b/tools/perf/builtin-lock.c > > @@ -495,6 +495,12 @@ struct trace_lock_handler { > > > > int (*release_event)(struct evsel *evsel, > > struct perf_sample *sample); > > + > > + int (*contention_begin_event)(struct evsel *evsel, > > + struct perf_sample *sample); > > + > > + int (*contention_end_event)(struct evsel *evsel, > > + struct perf_sample *sample); > > Would it make sense to add a comment here about LOCKDEP and LOCK_STAT? > It could be confusing if the handler isn't called on different > kernels.
Sure, I'll add some comments here.
Thanks, Namhyung
| |