]> git.baikalelectronics.ru Git - kernel.git/commit
perf trace: Fix ')' placement in "interrupted" syscall lines
authorArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 7 Jan 2019 19:24:27 +0000 (16:24 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 8 Jan 2019 16:28:12 +0000 (13:28 -0300)
commit5f06dcbbadf382979422914f6d75179ba0d949a8
treec0e38fe82cd949883b28159c2fc00e19a324cc4a
parent5cd03a1126654b2634d6ecf65a1e09b227c21a8c
perf trace: Fix ')' placement in "interrupted" syscall lines

When we get the sys_enter for a syscall we check if the last one is
still waiting for its matching sys_exit, if so we print this:

   468.753 (         ): firefox/32382 poll(ufds: 0x7f3988d3dd00, nfds: 7, timeout_msecs: 4294967295)     ...
   449.575 ( 0.004 ms): Softwar~cThrea/32434 futex(uaddr: 0x7f39a18a9b70, op: WAKE|PRIVATE_FLAG, val: 1)           = 0

At some point we'll get that poll sys_exit event and will print a "[continued]" line.

While making the sizing of the alignment after the syscall arg list and
its result configurable, so that we can mimic strace, which uses a
smaller alingment by default, a bug was introduced where the closing
parens appeared before the syscall name and its arg list, fix it.

Fixes: 4ed5933b4c6d ("perf trace: Add alignment spaces after the closing parens")
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Luis Cláudio Gonçalves <lclaudio@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: https://lkml.kernel.org/n/tip-oi45i54s59h1w1kmgpzrfuum@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-trace.c