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 4734BC0015E for ; Fri, 11 Aug 2023 17:10:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236402AbjHKRKv (ORCPT ); Fri, 11 Aug 2023 13:10:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45176 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235270AbjHKRKv (ORCPT ); Fri, 11 Aug 2023 13:10:51 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A34AC26BC; Fri, 11 Aug 2023 10:10:25 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id B5B49677D5; Fri, 11 Aug 2023 17:10:05 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2BF09C433C8; Fri, 11 Aug 2023 17:10:03 +0000 (UTC) Date: Fri, 11 Aug 2023 13:10:01 -0400 From: Steven Rostedt To: "Masami Hiramatsu (Google)" Cc: Florent Revest , Alexei Starovoitov , linux-trace-kernel@vger.kernel.org, LKML , Martin KaFai Lau , bpf , Sven Schnelle , Alexei Starovoitov , Jiri Olsa , Arnaldo Carvalho de Melo , Daniel Borkmann , Alan Maguire , Mark Rutland , Peter Zijlstra , Thomas Gleixner Subject: Re: [RFC PATCH v2 1/6] fprobe: Use fprobe_regs in fprobe entry handler Message-ID: <20230811131001.7b22a17d@gandalf.local.home> In-Reply-To: <20230810071330.d41a728f996f76e3243f469e@kernel.org> References: <169139090386.324433.6412259486776991296.stgit@devnote2> <169139091575.324433.13168120610633669432.stgit@devnote2> <20230809231011.b125bd68887a5659db59905e@kernel.org> <20230810071330.d41a728f996f76e3243f469e@kernel.org> X-Mailer: Claws Mail 3.19.1 (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 Thu, 10 Aug 2023 07:13:30 +0900 Masami Hiramatsu (Google) wrote: > > > > I hope that makes my thoughts clearer? It's a hairy topic ahah > > Ah, I see your point. > > static void fprobe_init(struct fprobe *fp) > { > fp->nmissed = 0; > if (fprobe_shared_with_kprobes(fp)) > fp->ops.func = fprobe_kprobe_handler; > else > fp->ops.func = fprobe_handler; > fp->ops.flags |= FTRACE_OPS_FL_SAVE_REGS; <---- This flag! > } > > So it should be FTRACE_OPS_FL_ARGS. Let me fix that. Yes, this was the concern that I was bringing up, where I did not see an advantage of fprobes over kprobes using ftrace, because they both were saving all registers. -- Steve