summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorAthira Rajeev <atrajeev@linux.ibm.com>2026-06-07 19:32:45 +0530
committerNamhyung Kim <namhyung@kernel.org>2026-06-30 10:24:20 -0700
commit2b123a1a09e94e02148157cdafd261f06b534940 (patch)
tree2603ee31b918c9efa23c6b6f2e2100e13afeb5e5 /tools/perf/scripts/python
parent270e3f076b509c24d8cf69dde11db12d64706113 (diff)
tools/perf/sched: Update process names of processes in zombie state for both -s and -S options
In redhat perftool testsuite, observed fail for this test: -- [ FAIL ] -- perf_sched :: test_timehist :: --with-summary (output regexp parsing) This led to analysis of "perf sched timehist" summary options. # perf sched record -a -o ./perf.data -- sleep 0.1 This will record using perf sched record perf sched timeliest has two options "-s" and "-S" # perf sched -i ./perf.data timehist -S -S : Captures summary also at the end # perf sched -i ./perf.data timehist -s -s : Captures only summary The test saves -s result which has only summary and compares with summary which comes at the end from -S . Since there is a difference in these two, test fails. Checking the behaviour change in -S and -s results, difference is: rcu_sched[16] 2 4 0.013 0.001 0.003 0.006 33.23 0 migration/11[73] 2 1 0.006 0.006 0.006 0.006 0.00 0 migration/3[33] 2 1 0.006 0.006 0.006 0.006 0.00 0 - :216753[216753] -1 1 0.041 0.041 0.041 0.041 0.00 0 + sleep[216753] -1 1 0.041 0.041 0.041 0.041 0.00 0 migration/8[58] 2 1 0.005 0.005 0.005 0.005 0.00 0 NetworkManager[811] 1 2 0.089 0.028 0.044 0.060 36.06 0 migration/13[83] 2 1 0.005 0.005 0.005 0.005 0.00 0 Here 216753 is pid for sleep which is a zombie process. This is happening in latest kernel due to an update in "-S" result. In -S, the process name appears in the results "sleep[216753]", where as in the -s, only pid is present in the summary result ":216753[216753]". After commit 39f473f6d0b2 ("perf sched timehist: decode process names of processes in zombie state") for -S option, if process name is using pid, it uses different way to set it. So that we get the process name and not just Pid. This change went in only for timehist_print_sample() function. Add this improvement in generic place so that even -s option (which captures summary) also will have meaningful information. Acked-by: Namhyung Kim <namhyung@kernel.org> Tested-by: Venkat Rao Bagalkote <venkat88@linux.ibm.com> Signed-off-by: Athira Rajeev <atrajeev@linux.ibm.com> Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions