Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1112241imu; Fri, 9 Nov 2018 11:07:10 -0800 (PST) X-Google-Smtp-Source: AJdET5fzWpUIN8XIgJ6uO0MXliX+VPfvN+AUGnWMSii0AppcAnHZv6EFim3+GA7WBgEQmEpQkVkP X-Received: by 2002:a17:902:7797:: with SMTP id o23-v6mr10299462pll.30.1541790430205; Fri, 09 Nov 2018 11:07:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541790430; cv=none; d=google.com; s=arc-20160816; b=rYkWlbypqroa4/JWlLI+B93+ADOxy19yk063dZUriPQu7jT7XXcSyhRTLwpD+8+yg6 T9pn+D6JGgwSrm1f/GmYmvilMav5DpHjhL/YDuHirFg88Vr2pxrrBYbLJ8RV9M9Rmbje n68u0iCiU6ngmdYqo7PDaJ34C5gWl8XlvpYDhdzOoWUk1vJ4muPOMYF0t92gbz3eMALN 5HR2cIXN0vmpqgVD1TgB5eohxFiWBypxD2JEiYYyNyfyKYSd+0RJgtG0+kcLljYRRUhg zTtZwmyCf5VTOsrUzEPK3hxohX6qI65LfsaLSmuRJL4RZFVTP6T8BmQfiOxNt0uu9s5n YbDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:references:message-id :content-transfer-encoding:cc:date:in-reply-to:from:subject :mime-version:dkim-signature; bh=LqUOZkxahT2we8U88Q+WPC6iRMFZcMRyYwEEgRdSPZY=; b=sGZMPZnJ/S1P+ePT4ZF+SW+/fIooSjUzrqJyEJ1DKEUoAKBdN8/FR7f2jm2TZz+xIH jQ0jPlW0KDcChT9+Ps5me755O7LGU/YIz580QerRLQC9Nff1oDeXjWBwhHMPc/q9br6N 5IP6AR9rveBzoAE8JrJ0o6HKUaW4IOGBI4+N2DV4RYHHFEwbMQVYOrp+Z9xQ6VeJkTFQ TgY4ttBoFY6+GsO0wosTPc9XZEn6z383PJ1+aHPWhHOmae+u5h2wfrHp6uVCgF6sZuGU Tkm6N+0vy69wadC2cjkYNpBVLNbnoOCuXZhB7DrireHjgwPyke3nylSLLi+vGwv9eVDL atng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amacapital-net.20150623.gappssmtp.com header.s=20150623 header.b=Pjr28Fn8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g11-v6si7205223pgu.301.2018.11.09.11.06.43; Fri, 09 Nov 2018 11:07:10 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@amacapital-net.20150623.gappssmtp.com header.s=20150623 header.b=Pjr28Fn8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729039AbeKJErr (ORCPT + 99 others); Fri, 9 Nov 2018 23:47:47 -0500 Received: from mail-pg1-f196.google.com ([209.85.215.196]:44781 "EHLO mail-pg1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728183AbeKJErr (ORCPT ); Fri, 9 Nov 2018 23:47:47 -0500 Received: by mail-pg1-f196.google.com with SMTP id w3-v6so1218610pgs.11 for ; Fri, 09 Nov 2018 11:05:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amacapital-net.20150623.gappssmtp.com; s=20150623; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=LqUOZkxahT2we8U88Q+WPC6iRMFZcMRyYwEEgRdSPZY=; b=Pjr28Fn8Sg5vE0YeLxZwWZW4syL6DFCbnm2QY4FuYVD9pdb6b3Qj6f9/x/t49hzv7Z 4clYpxWjWqOA62CiPP2BbEMAzByHEwGJW4M8/8Zh7jWJXVizeFhBAz430BBZT/zL0A9O D1ZEAUzdYQUkjf7bqp8nlA4IlWkKUrhsuHCECXIrjyzS11qreHgOfIqXa2ArwqH6I01r kOlns0zdpVjmrcORFDXt6mtO0LsLjCki8rzMjKFVSb/algeG6T4dy8ZsiR03l8oxLovH n585XDc6PEAJivWCsE+hNrTut299133P4BZmNN8ginQ3M1s37pqaIYv4MC3coHq+0sLs SNqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=LqUOZkxahT2we8U88Q+WPC6iRMFZcMRyYwEEgRdSPZY=; b=J9ez7HefameFjdv2HRNwRMc355cpPU5R+mC9UsudxhfIUzUXOT2gDZcV4OAMzKWr4A pW3v7OHqq+URmWAd+GSf6vQrvHjGRzEj0E7g+ajGpzsB0isKIufTi0uAGr8eJ/XgPxyb I/SHgkdGlOEijpWBx9/kJhe9At1s3mM4MFgmzjPkZKbhakInt+zj6eXVHLRWFXqfX/3w K7KyCPLpHOMDXXdPgr8igk0ulQjKz6G8jLayeZfIm2XlP9TkAu0ErXoRJkvcb6Xcj1A5 6oQMPEx3oA61iUcwYIKp6Ow8DAqOdE4E4RiOsNQKGqQA6UwTMvFM/zz3xAnLfJzLqDtD EApQ== X-Gm-Message-State: AGRZ1gJLdO3MgCPtqhzkixfbWI/HdT2fhyeWO1Ynl8hiI+qiATTCQ7U1 dJ9Ig/dmD1yLnq+5fiLW7bLnQQ== X-Received: by 2002:a62:de06:: with SMTP id h6-v6mr10231237pfg.36.1541790353575; Fri, 09 Nov 2018 11:05:53 -0800 (PST) Received: from [100.121.81.84] (188.sub-174-214-11.myvzw.com. [174.214.11.188]) by smtp.gmail.com with ESMTPSA id x123-v6sm9193901pfb.124.2018.11.09.11.05.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 09 Nov 2018 11:05:52 -0800 (PST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (1.0) Subject: Re: [PATCH RFC 0/3] Static calls From: Andy Lutomirski X-Mailer: iPhone Mail (16A404) In-Reply-To: <20181109134241.5f4ce3be@gandalf.local.home> Date: Fri, 9 Nov 2018 11:05:51 -0800 Cc: Josh Poimboeuf , Andy Lutomirski , Ingo Molnar , LKML , X86 ML , Ard Biesheuvel , Peter Zijlstra , Thomas Gleixner , Linus Torvalds , Masami Hiramatsu , Jason Baron , Jiri Kosina , David Laight , Borislav Petkov Content-Transfer-Encoding: quoted-printable Message-Id: <979DB163-EFBD-41BB-8481-155AAF526E72@amacapital.net> References: <20181109072811.GB86700@gmail.com> <20181109152139.zig45f6gp24btfbc@treble> <20181109164137.5cngbfrkm4ihj4ra@treble> <20181109134241.5f4ce3be@gandalf.local.home> To: Steven Rostedt Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Nov 9, 2018, at 10:42 AM, Steven Rostedt wrote: >=20 > On Fri, 9 Nov 2018 10:41:37 -0600 > Josh Poimboeuf wrote: >=20 >>> On Fri, Nov 09, 2018 at 09:21:39AM -0600, Josh Poimboeuf wrote: >>>> On Fri, Nov 09, 2018 at 07:16:17AM -0800, Andy Lutomirski wrote: =20 >>>>> On Thu, Nov 8, 2018 at 11:28 PM Ingo Molnar wrote: = =20 >>>>>=20 >>>>>=20 >>>>> All other usecases are bonus, but it would certainly be interesting to= >>>>> investigate the impact of using these APIs for tracing: that too is a >>>>> feature enabled everywhere but utilized only by a small fraction of Li= nux >>>>> users - so literally every single cycle or instruction saved or hot-pa= th >>>>> shortened is a major win. =20 >>>>=20 >>>> For tracing, we'd want static_call_set_to_nop() or something like that,= right? =20 >>>=20 >>> Are we talking about tracepoints? Or ftrace? =20 >>=20 >> Since ftrace changes calls to nops, and vice versa, I assume you meant >> ftrace. I don't think ftrace is a good candidate for this, as it's >> inherently more flexible than this API would reasonably allow. >>=20 >=20 > Not sure what Andy was talking about, but I'm currently implementing > tracepoints to use this, as tracepoints use indirect calls, and are a > prime candidate for static calls, as I showed in my original RFC of > this feature. >=20 >=20 Indeed. Although I had assumed that tracepoints already had appropriate jump label m= agic.=