Re: [BUG] perf: buildid not managed properly when cmd path isrelative

From: Arnaldo Carvalho de Melo
Date: Tue Jun 01 2010 - 14:39:16 EST


Em Thu, May 27, 2010 at 03:46:16PM +0200, Stephane Eranian escreveu:
> I ran into another problem while running more tests with perf record,
> perf buildid-list.

> I do the following:

> $ perf record foo/noploop 5 ; perf buildid-list
> 54b1e7cc3cf52e0db255aab44ce7538eb62655b8 [kernel.kallsyms]
> 875ae61623e89f408b425ca0486a9ec99e3ac73e
> /home/eranian/perfmon/official/tip/build/tools/perf/foo/noploop
>
> I know I have samples in noploop:
> $ perf report -D
> 0x10a0 [0x20]: PERF_RECORD_SAMPLE(IP, 2): 14721/14721: 0x4006d6 period: 2351576
> ... thread: noploop:14721
> ...... dso: ./foo/noploop

> But if I ask with buildid-list (like per-archive is doing) then I get:
> $ perf buildid-list --with-hits
> 54b1e7cc3cf52e0db255aab44ce7538eb62655b8 [kernel.kallsyms]
> 0000000000000000000000000000000000000000 ./foo/noploop

> The builid is bogus for noploop and it is relative path not full anymore.

Hi Stephane,

Can you please try the following patch?

Thanks in advance,

- Arnaldo