public inbox for linux-trace-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org,
	Peter Zijlstra <peterz@infradead.org>
Cc: Masami Hiramatsu <mhiramat@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Brian Geffon <bgeffon@google.com>,
	John Stultz <jstultz@google.com>, Ian Rogers <irogers@google.com>,
	Suleiman Souhlal <suleiman@google.com>
Subject: Re: [PATCH v3 0/3] tracing: Read user data from futex system call trace event
Date: Wed, 1 Apr 2026 13:15:36 -0400	[thread overview]
Message-ID: <20260401131536.443b073e@gandalf.local.home> (raw)
In-Reply-To: <20260331181349.062575155@kernel.org>


Peter,

Any thoughts on this version?

-- Steve


On Tue, 31 Mar 2026 14:13:49 -0400
Steven Rostedt <rostedt@kernel.org> wrote:

> We are looking at the performance of futexes and require a bit more
> information when tracing them.
> 
> The two patches here extend the system call reading of user space to
> create specific handling of the futex system call. It now reads the
> user space relevant data (the addr, utime and addr2), as well as
> parses the flags. This adds a little smarts to the trace event as
> it only shows the parameters that are relevant, as well as parses
> utime as either a timespec or as val2 depending on the futex_op.
> 
> Here's an example of the new output:
> 
>  sys_futex(uaddr: 0x56196292e830 (0), FUTEX_WAKE|FUTEX_PRIVATE_FLAG)
>  sys_futex(uaddr: 0x56196292e834 (0x4a7) tid: 1191, FUTEX_UNLOCK_PI|FUTEX_PRIVATE_FLAG)
>  sys_futex(uaddr: 0x56196292e834 (0) tid: 0, FUTEX_LOCK_PI|FUTEX_PRIVATE_FLAG)
>  sys_futex(uaddr: 0x56196292e830 (0), FUTEX_WAIT|FUTEX_PRIVATE_FLAG)
>  sys_futex(uaddr: 0x56196292e838 (0), FUTEX_WAIT_REQUEUE_PI|FUTEX_PRIVATE_FLAG, timespec: 0x7ffc1b91a9f0 (163.048528790), uaddr2: 0x56196292e834 (4aa), val3: 0)
>  sys_futex(uaddr: 0x56196292e834 (0x4aa) tid: 1194, FUTEX_LOCK_PI|FUTEX_PRIVATE_FLAG)
>  sys_futex(uaddr: 0x56196292e838 (0), FUTEX_WAIT_REQUEUE_PI|FUTEX_PRIVATE_FLAG, timespec: 0x7ffc1b91a9f0 (163.048528790), uaddr2: 0x56196292e834 (800004aa), val3: 0)
>  sys_futex(uaddr: 0x7f7ed6b29990 (0x4ab), FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME)
>  sys_futex(uaddr: 0x56196292e834 (0x800004aa) tid: 1194 (WAITERS), FUTEX_LOCK_PI|FUTEX_PRIVATE_FLAG)
>  sys_futex(uaddr: 0x56196292e838 (0), FUTEX_WAIT_REQUEUE_PI|FUTEX_PRIVATE_FLAG, timespec: 0x7ffc1b91a9f0 (163.048528790), uaddr2: 0x56196292e834 (800004aa), val3: 0)
>  sys_futex(uaddr: 0x56196292e834 (0x800004aa) tid: 1194 (WAITERS), FUTEX_LOCK_PI|FUTEX_PRIVATE_FLAG)
> 
> Changes since v2: https://lore.kernel.org/all/20260310200954.285663884@kernel.org/
> 
> - Removed unused "buf" variable (kernel test robot)
> 
> - Iterate __futex_cmds[] make the print statement.
>   Note this required exposing __futex_cmds[] to trace_syscall.c
>   (Masami Hiramatsu)
> 
> - Added back val statement (with the move to futex/syscall.c the
>   third parameter was dropped).
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace.git
> futex/core
> 
> Head SHA1: 79b0609ad15b24d0bbfb1790e17902a6c210ae69
> 
> 
> Steven Rostedt (3):
>       tracing: Have futex syscall trace event show specific user data
>       tracing: Update futex syscall trace event to show more commands
>       tracing: Show TID and flags for PI futex system call trace event
> 
> ----
>  include/linux/futex.h         |  39 ++++++-
>  kernel/futex/syscalls.c       | 137 +++++++++++++++++++++---
>  kernel/trace/trace_syscalls.c | 237 +++++++++++++++++++++++++++++++++++++++++-
>  3 files changed, 396 insertions(+), 17 deletions(-)


  parent reply	other threads:[~2026-04-01 17:14 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-31 18:13 [PATCH v3 0/3] tracing: Read user data from futex system call trace event Steven Rostedt
2026-03-31 18:13 ` [PATCH v3 1/3] tracing: Have futex syscall trace event show specific user data Steven Rostedt
2026-04-01 18:07   ` Ian Rogers
2026-04-01 18:17     ` Steven Rostedt
2026-03-31 18:13 ` [PATCH v3 2/3] tracing: Update futex syscall trace event to show more commands Steven Rostedt
2026-03-31 18:13 ` [PATCH v3 3/3] tracing: Show TID and flags for PI futex system call trace event Steven Rostedt
2026-04-01 17:15 ` Steven Rostedt [this message]
2026-04-01 19:31 ` [PATCH v3 0/3] tracing: Read user data from " Thomas Gleixner
2026-04-01 20:13   ` Peter Zijlstra
2026-04-01 20:19   ` Steven Rostedt
2026-04-01 20:25     ` Peter Zijlstra

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260401131536.443b073e@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=akpm@linux-foundation.org \
    --cc=bgeffon@google.com \
    --cc=irogers@google.com \
    --cc=jstultz@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-trace-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=mhiramat@kernel.org \
    --cc=peterz@infradead.org \
    --cc=suleiman@google.com \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox