lkml.org 
[lkml]   [2024]   [Mar]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH v4 2/6] perf stat: Fork and launch perf record when perf stat needs to get retire latency value for a metric.
> We could use -a -C and cgroup together. I think this could be a useful use case.
> There could be other improvement to the implementation in next step. But I believe

I don't know how you would improve it. A lot of the problems are fairly
fundamental.

> current implementation could provide users the access to our new feature with
> accurate results
> and without adding too much overhead.

perf record increases the overhead a lot over a perf stat! Sampling
is much more expensive than counting.

That should be at least a order of magnitude difference.
Another advantage of doing it separately.

That will also make it inaccurate.

Please do a proper implementation. This one is no good.

You can likely reuse a lot of your code:

- Add a perf calibrate to run the profile step separately that generates the JSON
- Add a --metrics option to perf to read the resulting JSON
- Add some mechanism to read a default JSON as fallback. I guess this
one could be compiled in to avoid a dependency on an installed file.

-Andi

\
 
 \ /
  Last update: 2024-03-14 01:00    [W:0.047 / U:0.844 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site