From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 36DB6C77B7C for ; Fri, 5 May 2023 21:49:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232410AbjEEVtD (ORCPT ); Fri, 5 May 2023 17:49:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49120 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232290AbjEEVtB (ORCPT ); Fri, 5 May 2023 17:49:01 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F372D98; Fri, 5 May 2023 14:49:00 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 78EEA64113; Fri, 5 May 2023 21:49:00 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C6A37C433EF; Fri, 5 May 2023 21:48:58 +0000 (UTC) Date: Fri, 5 May 2023 17:48:56 -0400 From: Steven Rostedt To: "Masami Hiramatsu (Google)" Cc: linux-trace-kernel@vger.kernel.org, linux-kernel@vger.kernel.org, Florent Revest , Mark Rutland , Will Deacon , Mathieu Desnoyers , Martin KaFai Lau , bpf@vger.kernel.org Subject: Re: [PATCH v9.1 07/11] tracing/probes: Add $$args meta argument for all function args Message-ID: <20230505174856.04ca1e6a@gandalf.local.home> In-Reply-To: <168299390127.3242086.2714570777321787734.stgit@mhiramat.roam.corp.google.com> References: <168299383880.3242086.7182498102007986127.stgit@mhiramat.roam.corp.google.com> <168299390127.3242086.2714570777321787734.stgit@mhiramat.roam.corp.google.com> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-trace-kernel@vger.kernel.org On Tue, 2 May 2023 11:18:21 +0900 "Masami Hiramatsu (Google)" wrote: > From: Masami Hiramatsu (Google) > > Add the '$$args' meta fetch argument for function-entry probe events. This Hmm, couldn't we just use $args ? That would be different from $arg1, $arg2, etc. The $$ to me would be either the bash pid of current, or perhaps it would be just to use a dollar sign. I don't see the precedence of $$args being a "full expand". -- Steve > will be expanded to the all arguments of the function and the tracepoint > using BTF function argument information. > > e.g. > # echo 'p vfs_read $$args' >> dynamic_events > # echo 'f vfs_write $$args' >> dynamic_events > # echo 't sched_overutilized_tp $$args' >> dynamic_events > # cat dynamic_events > p:kprobes/p_vfs_read_0 vfs_read file=file buf=buf count=count pos=pos > f:fprobes/vfs_write__entry vfs_write file=file buf=buf count=count pos=pos > t:tracepoints/sched_overutilized_tp sched_overutilized_tp rd=rd overutilized=overutilized > > Signed-off-by: Masami Hiramatsu (Google) > ---