All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] perf trace: don't show comm/tid for regular syscalls for single-pid traces
@ 2025-08-21 16:58 Anubhav Shelat
  2025-09-11 15:27 ` Anubhav Shelat
  2025-09-11 22:00 ` Namhyung Kim
  0 siblings, 2 replies; 5+ messages in thread
From: Anubhav Shelat @ 2025-08-21 16:58 UTC (permalink / raw)
  To: mpetlan, acme, namhyung, irogers, linux-perf-users
  Cc: peterz, mingo, mark.rutland, alexander.shishkin, jolsa,
	adrian.hunter, kan.liang, dapeng1.mi, james.clark, Anubhav Shelat

Previously when attaching perf trace to a specific pid the output would
look like this:

         ? (         ): vest/616160  ... [continued]: clock_nanosleep())                                  = 0
     0.041 ( 0.013 ms): vest/616160 fstat(statbuf: 0xfffff2c60038)                                        = 0
     0.073 ( 0.008 ms): vest/616160 read(buf: 0x3bede330, count: 4096)                                    = 17
     0.090 (1000.095 ms): vest/616160 clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff2c601d8) = 0
  1000.210 ( 0.136 ms): vest/616160 openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
  1000.361 ( 0.004 ms): vest/616160 fstat(fd: 3, statbuf: 0xfffff2c60088)                                 = 0
  1000.375 ( 0.018 ms): vest/616160 write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
  1000.395 ( 0.072 ms): vest/616160 close(fd: 3)                                                          = 0
  1000.476 (         ): vest/616160 exit_group()

which would cause an error in the perftool-testsuite since the comm/tid
shouldn't be in trace lines for regular syscalls. With this change the
output looks like this:

         ? (         ): vest/612038  ... [continued]: clock_nanosleep())                                  = 0
     0.039 ( 0.012 ms): fstat(statbuf: 0xfffff8e94cb8)                                        = 0
     0.069 ( 0.008 ms): read(buf: 0x3b997330, count: 4096)                                    = 17
     0.086 (1000.436 ms): clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff8e94e58) = 0
  1000.545 ( 0.136 ms): openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
  1000.700 ( 0.006 ms): fstat(fd: 3, statbuf: 0xfffff8e94d08)                                 = 0
  1000.720 ( 0.024 ms): write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
  1000.750 ( 0.073 ms): close(fd: 3)                                                          = 0
  1000.833 (         ): vest/612038 exit_group()

Signed-off-by: Anubhav Shelat <ashelat@redhat.com>
---
 tools/perf/builtin-trace.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
index fe737b3ac6e6..4cc38ee6aad9 100644
--- a/tools/perf/builtin-trace.c
+++ b/tools/perf/builtin-trace.c
@@ -2955,11 +2955,17 @@ static int trace__sys_exit(struct trace *trace, struct evsel *evsel,
 	if (trace->summary_only || (ret >= 0 && trace->failure_only))
 		goto out;
 
-	trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
-
 	if (ttrace->entry_pending) {
+		if (trace->opts.target.pid) {
+			if (trace->show_tstamp)
+				printed = trace__fprintf_tstamp(trace, ttrace->entry_time, trace->output);
+			if (trace->show_duration)
+				printed += fprintf_duration(duration, duration_calculated, trace->output);
+		} else
+			trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
 		printed = fprintf(trace->output, "%s", ttrace->entry_str);
 	} else {
+		trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
 		printed += fprintf(trace->output, " ... [");
 		color_fprintf(trace->output, PERF_COLOR_YELLOW, "continued");
 		printed += 9;
-- 
2.50.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] perf trace: don't show comm/tid for regular syscalls for single-pid traces
  2025-08-21 16:58 [PATCH] perf trace: don't show comm/tid for regular syscalls for single-pid traces Anubhav Shelat
@ 2025-09-11 15:27 ` Anubhav Shelat
  2025-09-16 14:33   ` Arnaldo Carvalho de Melo
  2025-09-11 22:00 ` Namhyung Kim
  1 sibling, 1 reply; 5+ messages in thread
From: Anubhav Shelat @ 2025-09-11 15:27 UTC (permalink / raw)
  To: mpetlan, acme, namhyung, irogers, linux-perf-users

pinging

On Thu, Aug 21, 2025 at 12:59 PM Anubhav Shelat <ashelat@redhat.com> wrote:
>
> Previously when attaching perf trace to a specific pid the output would
> look like this:
>
>          ? (         ): vest/616160  ... [continued]: clock_nanosleep())                                  = 0
>      0.041 ( 0.013 ms): vest/616160 fstat(statbuf: 0xfffff2c60038)                                        = 0
>      0.073 ( 0.008 ms): vest/616160 read(buf: 0x3bede330, count: 4096)                                    = 17
>      0.090 (1000.095 ms): vest/616160 clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff2c601d8) = 0
>   1000.210 ( 0.136 ms): vest/616160 openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
>   1000.361 ( 0.004 ms): vest/616160 fstat(fd: 3, statbuf: 0xfffff2c60088)                                 = 0
>   1000.375 ( 0.018 ms): vest/616160 write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
>   1000.395 ( 0.072 ms): vest/616160 close(fd: 3)                                                          = 0
>   1000.476 (         ): vest/616160 exit_group()
>
> which would cause an error in the perftool-testsuite since the comm/tid
> shouldn't be in trace lines for regular syscalls. With this change the
> output looks like this:
>
>          ? (         ): vest/612038  ... [continued]: clock_nanosleep())                                  = 0
>      0.039 ( 0.012 ms): fstat(statbuf: 0xfffff8e94cb8)                                        = 0
>      0.069 ( 0.008 ms): read(buf: 0x3b997330, count: 4096)                                    = 17
>      0.086 (1000.436 ms): clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff8e94e58) = 0
>   1000.545 ( 0.136 ms): openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
>   1000.700 ( 0.006 ms): fstat(fd: 3, statbuf: 0xfffff8e94d08)                                 = 0
>   1000.720 ( 0.024 ms): write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
>   1000.750 ( 0.073 ms): close(fd: 3)                                                          = 0
>   1000.833 (         ): vest/612038 exit_group()
>
> Signed-off-by: Anubhav Shelat <ashelat@redhat.com>
> ---
>  tools/perf/builtin-trace.c | 10 ++++++++--
>  1 file changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
> index fe737b3ac6e6..4cc38ee6aad9 100644
> --- a/tools/perf/builtin-trace.c
> +++ b/tools/perf/builtin-trace.c
> @@ -2955,11 +2955,17 @@ static int trace__sys_exit(struct trace *trace, struct evsel *evsel,
>         if (trace->summary_only || (ret >= 0 && trace->failure_only))
>                 goto out;
>
> -       trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
> -
>         if (ttrace->entry_pending) {
> +               if (trace->opts.target.pid) {
> +                       if (trace->show_tstamp)
> +                               printed = trace__fprintf_tstamp(trace, ttrace->entry_time, trace->output);
> +                       if (trace->show_duration)
> +                               printed += fprintf_duration(duration, duration_calculated, trace->output);
> +               } else
> +                       trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
>                 printed = fprintf(trace->output, "%s", ttrace->entry_str);
>         } else {
> +               trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
>                 printed += fprintf(trace->output, " ... [");
>                 color_fprintf(trace->output, PERF_COLOR_YELLOW, "continued");
>                 printed += 9;
> --
> 2.50.1
>


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] perf trace: don't show comm/tid for regular syscalls for single-pid traces
  2025-08-21 16:58 [PATCH] perf trace: don't show comm/tid for regular syscalls for single-pid traces Anubhav Shelat
  2025-09-11 15:27 ` Anubhav Shelat
@ 2025-09-11 22:00 ` Namhyung Kim
  1 sibling, 0 replies; 5+ messages in thread
From: Namhyung Kim @ 2025-09-11 22:00 UTC (permalink / raw)
  To: Anubhav Shelat
  Cc: mpetlan, acme, irogers, linux-perf-users, peterz, mingo,
	mark.rutland, alexander.shishkin, jolsa, adrian.hunter, kan.liang,
	dapeng1.mi, james.clark

On Thu, Aug 21, 2025 at 12:58:32PM -0400, Anubhav Shelat wrote:
> Previously when attaching perf trace to a specific pid the output would
> look like this:
> 
>          ? (         ): vest/616160  ... [continued]: clock_nanosleep())                                  = 0
>      0.041 ( 0.013 ms): vest/616160 fstat(statbuf: 0xfffff2c60038)                                        = 0
>      0.073 ( 0.008 ms): vest/616160 read(buf: 0x3bede330, count: 4096)                                    = 17
>      0.090 (1000.095 ms): vest/616160 clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff2c601d8) = 0
>   1000.210 ( 0.136 ms): vest/616160 openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
>   1000.361 ( 0.004 ms): vest/616160 fstat(fd: 3, statbuf: 0xfffff2c60088)                                 = 0
>   1000.375 ( 0.018 ms): vest/616160 write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
>   1000.395 ( 0.072 ms): vest/616160 close(fd: 3)                                                          = 0
>   1000.476 (         ): vest/616160 exit_group()
> 
> which would cause an error in the perftool-testsuite since the comm/tid
> shouldn't be in trace lines for regular syscalls. With this change the
> output looks like this:

I'm not sure if it's the right test.  It's controlled by the
trace->multiple_threads condition which I believe should use
trace->opts.no_inherit condition instead of the attribute of the
first event.

Thanks,
Namhyung

> 
>          ? (         ): vest/612038  ... [continued]: clock_nanosleep())                                  = 0
>      0.039 ( 0.012 ms): fstat(statbuf: 0xfffff8e94cb8)                                        = 0
>      0.069 ( 0.008 ms): read(buf: 0x3b997330, count: 4096)                                    = 17
>      0.086 (1000.436 ms): clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff8e94e58) = 0
>   1000.545 ( 0.136 ms): openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
>   1000.700 ( 0.006 ms): fstat(fd: 3, statbuf: 0xfffff8e94d08)                                 = 0
>   1000.720 ( 0.024 ms): write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
>   1000.750 ( 0.073 ms): close(fd: 3)                                                          = 0
>   1000.833 (         ): vest/612038 exit_group()
> 
> Signed-off-by: Anubhav Shelat <ashelat@redhat.com>
> ---
>  tools/perf/builtin-trace.c | 10 ++++++++--
>  1 file changed, 8 insertions(+), 2 deletions(-)
> 
> diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
> index fe737b3ac6e6..4cc38ee6aad9 100644
> --- a/tools/perf/builtin-trace.c
> +++ b/tools/perf/builtin-trace.c
> @@ -2955,11 +2955,17 @@ static int trace__sys_exit(struct trace *trace, struct evsel *evsel,
>  	if (trace->summary_only || (ret >= 0 && trace->failure_only))
>  		goto out;
>  
> -	trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
> -
>  	if (ttrace->entry_pending) {
> +		if (trace->opts.target.pid) {
> +			if (trace->show_tstamp)
> +				printed = trace__fprintf_tstamp(trace, ttrace->entry_time, trace->output);
> +			if (trace->show_duration)
> +				printed += fprintf_duration(duration, duration_calculated, trace->output);
> +		} else
> +			trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
>  		printed = fprintf(trace->output, "%s", ttrace->entry_str);
>  	} else {
> +		trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
>  		printed += fprintf(trace->output, " ... [");
>  		color_fprintf(trace->output, PERF_COLOR_YELLOW, "continued");
>  		printed += 9;
> -- 
> 2.50.1
> 

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] perf trace: don't show comm/tid for regular syscalls for single-pid traces
  2025-09-11 15:27 ` Anubhav Shelat
@ 2025-09-16 14:33   ` Arnaldo Carvalho de Melo
  2025-09-16 16:35     ` Anubhav Shelat
  0 siblings, 1 reply; 5+ messages in thread
From: Arnaldo Carvalho de Melo @ 2025-09-16 14:33 UTC (permalink / raw)
  To: Anubhav Shelat; +Cc: mpetlan, namhyung, irogers, linux-perf-users

On Thu, Sep 11, 2025 at 11:27:15AM -0400, Anubhav Shelat wrote:
> pinging
> 
> On Thu, Aug 21, 2025 at 12:59 PM Anubhav Shelat <ashelat@redhat.com> wrote:
> >
> > Previously when attaching perf trace to a specific pid the output would
> > look like this:
> >
> >          ? (         ): vest/616160  ... [continued]: clock_nanosleep())                                  = 0
> >      0.041 ( 0.013 ms): vest/616160 fstat(statbuf: 0xfffff2c60038)                                        = 0
> >      0.073 ( 0.008 ms): vest/616160 read(buf: 0x3bede330, count: 4096)                                    = 17
> >      0.090 (1000.095 ms): vest/616160 clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff2c601d8) = 0
> >   1000.210 ( 0.136 ms): vest/616160 openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
> >   1000.361 ( 0.004 ms): vest/616160 fstat(fd: 3, statbuf: 0xfffff2c60088)                                 = 0
> >   1000.375 ( 0.018 ms): vest/616160 write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
> >   1000.395 ( 0.072 ms): vest/616160 close(fd: 3)                                                          = 0
> >   1000.476 (         ): vest/616160 exit_group()
> >
> > which would cause an error in the perftool-testsuite since the comm/tid
> > shouldn't be in trace lines for regular syscalls. With this change the
> > output looks like this:

But it is still appearing in some cases, no? The first one and the
exit_group() ones. Can you please try to make it be suppressed there as
well?

- Arnaldo

> >          ? (         ): vest/612038  ... [continued]: clock_nanosleep())                                  = 0
> >      0.039 ( 0.012 ms): fstat(statbuf: 0xfffff8e94cb8)                                        = 0
> >      0.069 ( 0.008 ms): read(buf: 0x3b997330, count: 4096)                                    = 17
> >      0.086 (1000.436 ms): clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff8e94e58) = 0
> >   1000.545 ( 0.136 ms): openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
> >   1000.700 ( 0.006 ms): fstat(fd: 3, statbuf: 0xfffff8e94d08)                                 = 0
> >   1000.720 ( 0.024 ms): write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
> >   1000.750 ( 0.073 ms): close(fd: 3)                                                          = 0
> >   1000.833 (         ): vest/612038 exit_group()
> >
> > Signed-off-by: Anubhav Shelat <ashelat@redhat.com>
> > ---
> >  tools/perf/builtin-trace.c | 10 ++++++++--
> >  1 file changed, 8 insertions(+), 2 deletions(-)
> >
> > diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
> > index fe737b3ac6e6..4cc38ee6aad9 100644
> > --- a/tools/perf/builtin-trace.c
> > +++ b/tools/perf/builtin-trace.c
> > @@ -2955,11 +2955,17 @@ static int trace__sys_exit(struct trace *trace, struct evsel *evsel,
> >         if (trace->summary_only || (ret >= 0 && trace->failure_only))
> >                 goto out;
> >
> > -       trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
> > -
> >         if (ttrace->entry_pending) {
> > +               if (trace->opts.target.pid) {
> > +                       if (trace->show_tstamp)
> > +                               printed = trace__fprintf_tstamp(trace, ttrace->entry_time, trace->output);
> > +                       if (trace->show_duration)
> > +                               printed += fprintf_duration(duration, duration_calculated, trace->output);
> > +               } else
> > +                       trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
> >                 printed = fprintf(trace->output, "%s", ttrace->entry_str);
> >         } else {
> > +               trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
> >                 printed += fprintf(trace->output, " ... [");
> >                 color_fprintf(trace->output, PERF_COLOR_YELLOW, "continued");
> >                 printed += 9;
> > --
> > 2.50.1
> >

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] perf trace: don't show comm/tid for regular syscalls for single-pid traces
  2025-09-16 14:33   ` Arnaldo Carvalho de Melo
@ 2025-09-16 16:35     ` Anubhav Shelat
  0 siblings, 0 replies; 5+ messages in thread
From: Anubhav Shelat @ 2025-09-16 16:35 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo; +Cc: mpetlan, namhyung, irogers, linux-perf-users

I think actually the test may have to be edited. Namhyung is right,
because unless "--no-inherit" is specified the trace needs to show the
comm/tid field to keep track of different processes in case the traced
program forks. Please disregard this change.

Thanks,
Anubhav

On Tue, Sep 16, 2025 at 10:34 AM Arnaldo Carvalho de Melo
<acme@kernel.org> wrote:
>
> On Thu, Sep 11, 2025 at 11:27:15AM -0400, Anubhav Shelat wrote:
> > pinging
> >
> > On Thu, Aug 21, 2025 at 12:59 PM Anubhav Shelat <ashelat@redhat.com> wrote:
> > >
> > > Previously when attaching perf trace to a specific pid the output would
> > > look like this:
> > >
> > >          ? (         ): vest/616160  ... [continued]: clock_nanosleep())                                  = 0
> > >      0.041 ( 0.013 ms): vest/616160 fstat(statbuf: 0xfffff2c60038)                                        = 0
> > >      0.073 ( 0.008 ms): vest/616160 read(buf: 0x3bede330, count: 4096)                                    = 17
> > >      0.090 (1000.095 ms): vest/616160 clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff2c601d8) = 0
> > >   1000.210 ( 0.136 ms): vest/616160 openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
> > >   1000.361 ( 0.004 ms): vest/616160 fstat(fd: 3, statbuf: 0xfffff2c60088)                                 = 0
> > >   1000.375 ( 0.018 ms): vest/616160 write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
> > >   1000.395 ( 0.072 ms): vest/616160 close(fd: 3)                                                          = 0
> > >   1000.476 (         ): vest/616160 exit_group()
> > >
> > > which would cause an error in the perftool-testsuite since the comm/tid
> > > shouldn't be in trace lines for regular syscalls. With this change the
> > > output looks like this:
>
> But it is still appearing in some cases, no? The first one and the
> exit_group() ones. Can you please try to make it be suppressed there as
> well?
>
> - Arnaldo
>
> > >          ? (         ): vest/612038  ... [continued]: clock_nanosleep())                                  = 0
> > >      0.039 ( 0.012 ms): fstat(statbuf: 0xfffff8e94cb8)                                        = 0
> > >      0.069 ( 0.008 ms): read(buf: 0x3b997330, count: 4096)                                    = 17
> > >      0.086 (1000.436 ms): clock_nanosleep(rqtp: { .tv_sec: 1, .tv_nsec: 0 }, rmtp: 0xfffff8e94e58) = 0
> > >   1000.545 ( 0.136 ms): openat(dfd: CWD, filename: "/tmp/something.txt", flags: CREAT|TRUNC|WRONLY, mode: IRUGO|IWUGO) = 3
> > >   1000.700 ( 0.006 ms): fstat(fd: 3, statbuf: 0xfffff8e94d08)                                 = 0
> > >   1000.720 ( 0.024 ms): write(fd: 3, buf: SOME TEST STRING\10, count: 17)                     = 17
> > >   1000.750 ( 0.073 ms): close(fd: 3)                                                          = 0
> > >   1000.833 (         ): vest/612038 exit_group()
> > >
> > > Signed-off-by: Anubhav Shelat <ashelat@redhat.com>
> > > ---
> > >  tools/perf/builtin-trace.c | 10 ++++++++--
> > >  1 file changed, 8 insertions(+), 2 deletions(-)
> > >
> > > diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
> > > index fe737b3ac6e6..4cc38ee6aad9 100644
> > > --- a/tools/perf/builtin-trace.c
> > > +++ b/tools/perf/builtin-trace.c
> > > @@ -2955,11 +2955,17 @@ static int trace__sys_exit(struct trace *trace, struct evsel *evsel,
> > >         if (trace->summary_only || (ret >= 0 && trace->failure_only))
> > >                 goto out;
> > >
> > > -       trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
> > > -
> > >         if (ttrace->entry_pending) {
> > > +               if (trace->opts.target.pid) {
> > > +                       if (trace->show_tstamp)
> > > +                               printed = trace__fprintf_tstamp(trace, ttrace->entry_time, trace->output);
> > > +                       if (trace->show_duration)
> > > +                               printed += fprintf_duration(duration, duration_calculated, trace->output);
> > > +               } else
> > > +                       trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
> > >                 printed = fprintf(trace->output, "%s", ttrace->entry_str);
> > >         } else {
> > > +               trace__fprintf_entry_head(trace, thread, duration, duration_calculated, ttrace->entry_time, trace->output);
> > >                 printed += fprintf(trace->output, " ... [");
> > >                 color_fprintf(trace->output, PERF_COLOR_YELLOW, "continued");
> > >                 printed += 9;
> > > --
> > > 2.50.1
> > >
>


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2025-09-16 16:36 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-21 16:58 [PATCH] perf trace: don't show comm/tid for regular syscalls for single-pid traces Anubhav Shelat
2025-09-11 15:27 ` Anubhav Shelat
2025-09-16 14:33   ` Arnaldo Carvalho de Melo
2025-09-16 16:35     ` Anubhav Shelat
2025-09-11 22:00 ` Namhyung Kim

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.