diff options
author | Howard Chu <howardchu95@gmail.com> | 2024-12-15 11:07:10 -0800 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2024-12-26 12:18:11 -0300 |
commit | 0255338d69754a021f239605a51e3a72d36294bb (patch) | |
tree | c20938d137d32baceac935df6d191e475e74a0e3 /scripts/gcc-plugins | |
parent | e5de3f9da5243a57747d0d4a4385a960205dfbb2 (diff) |
perf trace: Add tests for BTF general augmentation
Currently, we only have 'perf trace' augmentation tests for enum
arguments. This patch adds tests for more general syscall arguments,
such as struct pointers, strings, and buffers.
These tests utilize the 'perf config' system to configure 'the perf trace'
output, as suggested by Arnaldo Carvalho de Melo <acme@kernel.org>.
Committer testing:
root@number:~# perf test "BTF general"
109: perf trace BTF general tests : Ok
root@number:~# perf test -v "BTF general"
109: perf trace BTF general tests : Ok
root@number:~# perf test -vv "BTF general"
109: perf trace BTF general tests:
--- start ---
test child forked, pid 1410451
Checking if vmlinux BTF exists
Testing perf trace's string augmentation
Testing perf trace's buffer augmentation
Testing perf trace's struct augmentation
---- end(0) ----
109: perf trace BTF general tests : Ok
root@number:~#
It still fails sometimes, for instance when tested with:
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:~#
But we can go on from here and fix things up with followup patches.
Suggested-by: Arnaldo Carvalho de Melo <acme@kernel.org>
Signed-off-by: Howard Chu <howardchu95@gmail.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Kan Liang <kan.liang@linux.intel.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Link: https://lore.kernel.org/r/20241215190712.787847-2-howardchu95@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'scripts/gcc-plugins')
0 files changed, 0 insertions, 0 deletions