]> git.itanic.dy.fi Git - linux-stable/commit
perf test stat_bpf_counters_cgrp: Enhance perf stat cgroup BPF counter test
authorNamhyung Kim <namhyung@kernel.org>
Fri, 25 Aug 2023 16:41:52 +0000 (09:41 -0700)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 29 Aug 2023 17:16:15 +0000 (14:16 -0300)
commita84260e314029e6dc9904fd6eabf8d9fd7965351
tree1d7bfda4a41907ac0adca423c4ae75182e8c4ac0
parent68ca249c964f520af7f8763e22f12bd26b57b870
perf test stat_bpf_counters_cgrp: Enhance perf stat cgroup BPF counter test

It has system-wide test and cpu-list test but the cpu-list test fails
sometimes.  It runs sleep command on CPU1 and measure both user.slice
and system.slice cgroups by default (on systemd-based systems).

But if the system was idle enough, sometime the system.slice gets no
count and it makes the test failing.  Maybe that's because it only looks
at the CPU1, let's add CPU0 to increase the chance it finds some tasks.

Fixes: 7901086014bbaa3a ("perf test: Add a new test for perf stat cgroup BPF counter")
Reported-by: Arnaldo Carvalho de Melo <acme@kernel.org>
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: bpf@vger.kernel.org
Link: https://lore.kernel.org/r/20230825164152.165610-3-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/tests/shell/stat_bpf_counters_cgrp.sh