mirror of
https://git.proxmox.com/git/mirror_ubuntu-kernels.git
synced 2025-11-16 21:23:04 +00:00
To verify CSV output, just check the number of separators (",") using
the tr and wc commands like this.
grep -v "^#" ${result} | tr -d -c | wc -c
Now it expects 6 columns (and 5 separators) in the output, but it may
be changed later so count the field in the header first and compare it
to the actual output lines.
$ cat ${result}
# output: contended, total wait, max wait, avg wait, type, caller
1, 28787, 28787, 28787, spinlock, raw_spin_rq_lock_nested+0x1b
The test looks like below now:
$ sudo ./perf test -v contention
86: kernel lock contention analysis test :
--- start ---
test child forked, pid 2705822
Testing perf lock record and perf lock contention
Testing perf lock contention --use-bpf
Testing perf lock record and perf lock contention at the same time
Testing perf lock contention --threads
Testing perf lock contention --lock-addr
Testing perf lock contention --type-filter (w/ spinlock)
Testing perf lock contention --lock-filter (w/ tasklist_lock)
Testing perf lock contention --callstack-filter (w/ unix_stream)
Testing perf lock contention --callstack-filter with task aggregation
Testing perf lock contention CSV output
test child finished with 0
---- end ----
kernel lock contention analysis test: Ok
Acked-by: Ian Rogers <irogers@google.com>
Cc: Hao Luo <haoluo@google.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Song Liu <song@kernel.org>
Link: https://lore.kernel.org/r/20230628200141.2739587-5-namhyung@kernel.org
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
|
||
|---|---|---|
| .. | ||
| coresight | ||
| lib | ||
| buildid.sh | ||
| daemon.sh | ||
| lock_contention.sh | ||
| pipe_test.sh | ||
| probe_vfs_getname.sh | ||
| record_offcpu.sh | ||
| record.sh | ||
| record+probe_libc_inet_pton.sh | ||
| record+script_probe_vfs_getname.sh | ||
| record+zstd_comp_decomp.sh | ||
| stat_all_metricgroups.sh | ||
| stat_all_metrics.sh | ||
| stat_all_pfm.sh | ||
| stat_all_pmu.sh | ||
| stat_bpf_counters_cgrp.sh | ||
| stat_bpf_counters.sh | ||
| stat_metrics_values.sh | ||
| stat.sh | ||
| stat+csv_output.sh | ||
| stat+csv_summary.sh | ||
| stat+json_output.sh | ||
| stat+shadow_stat.sh | ||
| stat+std_output.sh | ||
| test_arm_callgraph_fp.sh | ||
| test_arm_coresight.sh | ||
| test_arm_spe_fork.sh | ||
| test_arm_spe.sh | ||
| test_brstack.sh | ||
| test_data_symbol.sh | ||
| test_intel_pt.sh | ||
| test_java_symbol.sh | ||
| test_perf_data_converter_json.sh | ||
| test_task_analyzer.sh | ||
| trace+probe_vfs_getname.sh | ||