mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-11-15 19:56:03 +00:00
perf test: Add file offset diagnostic test for corrupted perf.data
Add a shell test that verifies the file_offset diagnostic messages work correctly when perf encounters corrupted events. The test corrupts a MMAP2 event's size field in a recorded perf.data file, then checks that perf report produces warning messages that include both the file offset (e.g. "at offset 0x2738:") and the event type name with numeric id (e.g. "MMAP2 (10)"). This exercises the diagnostic improvements from the file_offset series, which retrofitted all skip/stop/error messages to include the position and type of the problematic event. Reviewed-by: Ian Rogers <irogers@google.com> Assisted-by: Claude:claude-opus-4.6 Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
parent
1e2c83f732
commit
078fc0430b
1 changed files with 91 additions and 0 deletions
91
tools/perf/tests/shell/data_file_offset_diagnostics.sh
Executable file
91
tools/perf/tests/shell/data_file_offset_diagnostics.sh
Executable file
Loading…
Add table
Add a link
Reference in a new issue