Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp240991imu; Thu, 3 Jan 2019 18:38:12 -0800 (PST) X-Google-Smtp-Source: ALg8bN6b4l0ONeXGNt7jzcQm2EjM/sm8G8gnr/hAoFxe+4d6lzSo6QfJp3XnmE6OPmfcWDn4cnaS X-Received: by 2002:a17:902:d70b:: with SMTP id w11mr50069644ply.294.1546569492101; Thu, 03 Jan 2019 18:38:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546569492; cv=none; d=google.com; s=arc-20160816; b=euYTDdParQVN0hlZ0iDE5qyF8bY44vcj9e5cT7SZeEzv9/LTIFgis22WrdWWv1etAM SB+99DYkcFNkrS2xGwJT+m6VjNFUi3FTUg4PFmmaRegADr6LP83FqMes7MMQVeG5T2SF LiMSjqQ273aaxgt76Ofp9PPZYWmFVymewttnLYET5GIuruU6LquaqCTh4xCvJc7nbUTR ycAq3v26R8cP6qEGpGOeKWo4HOCMuUE7HqvRVM+ft5fKmzof/wR27iHFKlFHzS7qGMxM xeeB53beiDy6NiIAoTngojpmh/GS3FiKDJF8jze055M3NtQ5ioHjqG/Rv+tK0A08xT+t yupg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=JageXkRWkJmFLe/R1hj3tZT8wUbnwt31usPXlGx6064=; b=dctfdYRpnK7ENyatPK0X4OouLfuidsdYE2L2RyCJuCxs8bWCN7/7tBEqspwgFODwt7 hLeWLABKpDC7FgTQ+eU6fO2dWFkak4SDj0cIaAllzyK4JKxbzwH8zLIxEAuQE+LcF5su eXujL7uZdL6VwHlRmdC6FYC0UMBjcKLfpriAzWctP92LTNmpNUrRWT6X6Iiw2uUGV1M6 dDX58nY6WUBgLUfJEUrw8U/39rS6Mfw5l79pL3G7XrFzImjTzdWfi1yOVQMmp1Ez6Vvr kP30jeAPPa9dLVwna12kxgtxZWATB7vXOV0WfIP2Q+UC6b7ghIyOjVNgmASj2QwgrI/M CeEw== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w15si7740151plk.357.2019.01.03.18.37.34; Thu, 03 Jan 2019 18:38:12 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727817AbfACUbN (ORCPT + 99 others); Thu, 3 Jan 2019 15:31:13 -0500 Received: from mx1.redhat.com ([209.132.183.28]:48208 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726036AbfACUbN (ORCPT ); Thu, 3 Jan 2019 15:31:13 -0500 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id E1657C059B8C; Thu, 3 Jan 2019 20:31:12 +0000 (UTC) Received: from treble (ovpn-125-50.rdu2.redhat.com [10.10.125.50]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 4390D1001F41; Thu, 3 Jan 2019 20:31:11 +0000 (UTC) Date: Thu, 3 Jan 2019 14:31:09 -0600 From: Josh Poimboeuf To: Nadav Amit Cc: Andy Lutomirski , Ingo Molnar , Peter Zijlstra , Edward Cree , "H . Peter Anvin" , Thomas Gleixner , LKML , X86 ML , Paolo Abeni , Borislav Petkov , David Woodhouse , Ard Biesheuvel Subject: Re: [RFC v2 0/6] x86: dynamic indirect branch promotion Message-ID: <20190103203109.cdck5kwck5gnkko7@treble> References: <20181231072112.21051-1-namit@vmware.com> <20190103181057.lflra4lkoaeg2btv@treble> <7FA580EA-9DEA-4813-8832-F1BE034A857C@vmware.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <7FA580EA-9DEA-4813-8832-F1BE034A857C@vmware.com> User-Agent: NeoMutt/20180716 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Thu, 03 Jan 2019 20:31:13 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 03, 2019 at 06:30:08PM +0000, Nadav Amit wrote: > > On Jan 3, 2019, at 10:10 AM, Josh Poimboeuf wrote: > > > > On Mon, Dec 31, 2018 at 07:53:06PM +0000, Nadav Amit wrote: > >>> On Dec 31, 2018, at 11:51 AM, Andy Lutomirski wrote: > >>> > >>> On Sun, Dec 30, 2018 at 11:20 PM Nadav Amit wrote: > >>>> This is a revised version of optpolines (formerly named retpolines) for > >>>> dynamic indirect branch promotion in order to reduce retpoline overheads > >>>> [1]. > >>> > >>> Some of your changelogs still call them "relpolines". > >>> > >>> I have a crazy suggestion: maybe don't give them a cute name at all? > >>> Where it's actually necessary to name them (like in a config option), > >>> use a description like CONFIG_DYNAMIC_DEVIRTUALIZATION or > >>> CONFIG_PATCH_INDIRECT_CALLS or something. > > > > Cute or not, naming is important. > > > > If you want a description instead of a name, it will be a challenge to > > describe it in 2-3 words. > > > > I have no idea what "dynamic devirtualization" means. > > > > "Patch indirect calls" doesn't fully describe it either (and could be > > easily confused with static calls and some other approaches). > > > >> I’m totally fine with that (don’t turn me into a "marketing” guy). It was > >> just a way to refer to the mechanism. I need more feedback about the more > >> fundamental issues to go on. > > > > Naming isn't marketing. It's a real issue: it affects both usability > > and code readability. > > Well, allow me to be on the fence not this one. > > I look for the path of least resistance. I think it would be easiest if I > first manage to make Josh’s static calls to be less intrusive. For that, I > try to add in the GCC plugin an attribute to annotate the function pointers > whose calls should be promoted. However, I don’t manage to get the > declaration from the call instruction's rtx. If anyone has a pointer on how > it can be done, that’s would be very helpful. Ok. FYI, I'll be posting v3 in the next few days or so. -- Josh