Re: [PATCH 3/3] perf inject: Do not load map/dso when injecting build-id

From: Namhyung Kim
Date: Wed Sep 16 2020 - 21:31:57 EST


On Tue, Sep 15, 2020 at 7:05 PM Jiri Olsa <jolsa@xxxxxxxxxx> wrote:
>
> On Mon, Sep 14, 2020 at 11:18:59PM +0900, Namhyung Kim wrote:
> > @@ -478,19 +479,8 @@ static int perf_event__inject_buildid(struct perf_tool *tool,
> > if (thread__find_map(thread, sample->cpumode, sample->ip, &al)) {
> > if (!al.map->dso->hit) {
> > al.map->dso->hit = 1;
> > - if (map__load(al.map) >= 0) {
>
> nice, that might do some nice speedup, did you see any?

I've checked it but the speed up was tiny on my machine.
I guess it's because the machine was idle and had everything
in memory. But I also found some more points to improve.
Will share the result in the next spin.

Thanks
Namhyung