Re: [PATCH v4 0/2] perf trace: Add more tests for BTF-augmented perf trace

From: Howard Chu
Date: Mon Dec 23 2024 - 21:03:34 EST


Hello Arnaldo,

On Mon, Dec 23, 2024 at 11:40 AM Arnaldo Carvalho de Melo
<acme@xxxxxxxxxx> wrote:
>
> On Mon, Dec 23, 2024 at 04:02:43PM -0300, Arnaldo Carvalho de Melo wrote:
> > On Mon, Dec 16, 2024 at 11:58:46AM -0800, Namhyung Kim wrote:
> > > On Sun, Dec 15, 2024 at 11:07:09AM -0800, Howard Chu wrote:
> > > > Changes in v4:
> > > > - Use if -f to check the existence of vmlinux BTF, and exit if it
> > > > doesn't, so trace_test_string will not overwrite $err, and keep
> > > > running the test.
> > > >
> > > > Changes in v3:
> > > > - Add vmlinux BTF check, and skip the tests if it doesn't exist
> > > >
> > > > v1, v2:
> > > >
> > > > The previous version of the perf trace BTF general augmentation tests
> > > > didn't pass Shellcheck (thanks to Arnaldo Carvalho de Melo
> > > > <acme@xxxxxxxxxx> for pointing this out), this version uses bash instead
> > > > of POSIX shell to pass Shellcheck.
> > > >
> > > > This patch series also adds documentation for the new option
> > > > --force-btf, which is used in the tests.
> > > >
> > > > Link: https://lore.kernel.org/linux-perf-users/Zt9yiQq-n-W6I274@x1/
> > > >
> > > > Howard Chu (2):
> > > > perf trace: Add tests for BTF general augmentation
> > > > perf docs: Add documentation for --force-btf option
> > >
> > > Acked-by: Namhyung Kim <namhyung@xxxxxxxxxx>
> >
> > Thanks, applied to perf-tools-next,
>
> It fails when running in parallel mode, sometimes:
>
> 109: perf trace BTF general tests : FAILED!
>
> Then:
>
> root@number:~# perf stat --null -r 10 perf test "BTF general"
> 109: perf trace BTF general tests : Ok
> 109: perf trace BTF general tests : Ok
> 109: perf trace BTF general tests : Ok
> 109: perf trace BTF general tests : Ok
> 109: perf trace BTF general tests : FAILED!
> 109: perf trace BTF general tests : Ok
> 109: perf trace BTF general tests : Ok
> 109: perf trace BTF general tests : FAILED!
> 109: perf trace BTF general tests : Ok
> 109: perf trace BTF general tests : Ok
>
> Performance counter stats for 'perf test BTF general' (10 runs):
>
> 2.148 +- 0.293 seconds time elapsed ( +- 13.63% )
>
> root@number:~#
>
>
> So its not just when running in paralell, anyway, its merged, we can go
> on from what we got there.

Thanks, I will resolve this issue and send v5 along with the
documentation changes you suggested.

Thanks,
Howard
>
> - Arnaldo