Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2452154imu; Sat, 10 Nov 2018 15:23:29 -0800 (PST) X-Google-Smtp-Source: AJdET5ew+4pTLbPuq+RoU2TarChofSf8w7Pn9nSDOTwLF4xiYhlQ+wb36wVqzkCAbtOhrNFGvIQt X-Received: by 2002:aa7:80ce:: with SMTP id a14-v6mr6374553pfn.86.1541892209612; Sat, 10 Nov 2018 15:23:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541892209; cv=none; d=google.com; s=arc-20160816; b=eSME6bN3GRe7z6aayBs8LOfwMSSzcPo+4RZHEzECVHQV4vzmhf/trBCf7fxQK8D50w bUDs4jBSgsvW0Jy1yWtX1AderRblZ4BZJM8ZK+caw/NmJcu5CBRgjA5SKPmQPpAe62St Yxy2l8P3Z4QZE50b+exVck9fqUgcwi4mrfWvDMTTU0jcdpDwGnFAcjCRWLPBzbB1uWqo LvqwLBPcFyfSs4mqw2IP/SVRx0DJh2NjEAV7wGsul41BG4O2gLOc6jE2iiBa9rOd5kKh RuB3/nseGIr3QdcEHNI5TXbNVDhGhh+hVaVAvud61SnPICe45rnALzr3g6GIQnj4lOTR Mxew== 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-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=pcvfrR2weqwFeCK+WlufDQK7hMyRibZsLKYSvbC9F3s=; b=lKgUltJuQHNRl9DnTEY+oIbRBa88O9V/IBwc7mjViOdh6VcmVZY7hd1JGkuAIgyRQk +r6IVE2AqJs4Xh4PG/PElg07bFtBRqe+Jgbj0QmWe0XoUTleqQacZ09DARTs9RYUoceZ smMLf4IGQTTvurTFB3Y/K+IA7b2VUzPOe9Qhs+Xr+3iK3IalDxJOFngootC2YaQUtYin L3bT/ztTyHvVWQ5ScZayC7sUkKOascNcMWklwX0761hRHTRT15j/TDc++i9hADw1dqPd T1PaPYJbi0kr411mh/T6wDX9pFVFVetn4vjiWqa61kGKvPSXbY0O22FcUpJZtBrXcAHZ Kk9A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b=vaTz9YyF; 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 q15si12101538pgm.420.2018.11.10.15.23.13; Sat, 10 Nov 2018 15:23:29 -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=fail header.i=@infradead.org header.s=merlin.20170209 header.b=vaTz9YyF; 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 S1726947AbeKKJH5 (ORCPT + 99 others); Sun, 11 Nov 2018 04:07:57 -0500 Received: from merlin.infradead.org ([205.233.59.134]:50802 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725859AbeKKJH5 (ORCPT ); Sun, 11 Nov 2018 04:07:57 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=pcvfrR2weqwFeCK+WlufDQK7hMyRibZsLKYSvbC9F3s=; b=vaTz9YyFye7cpozLKKUwPXGoS A+GoN2RKkxvysS0DXkwIlhtqGanV4dyhmvbrkvKu44/EPr6e5QFjXMVFzLbWgwviI63LMF/ax4X6Y /fFEXGa4I/td88PZ3hnExzmZMEpGoQqoKhaBaEQEDLwrLrTOUoIidR62aMIqWmxWv01agehNfLzXc 2hAjfMTCVFyBkRwJUijDML5Amcdq1xa+yrBfrYRUyIS2yytQKUBiBrLuTLZVhChmPWUBAoh7xePft 4rURTs+zavf0o03CiVOK+aDT1/1yJfqiMJ3RC0vUeb+Ki9uNS6O0b94VbXvADP40EfQH2H1knYQDH WPH9Ym8+Q==; Received: from [64.114.255.114] (helo=worktop) by merlin.infradead.org with esmtpsa (Exim 4.90_1 #2 (Red Hat Linux)) id 1gLcYm-0000xX-3s; Sat, 10 Nov 2018 23:21:00 +0000 Received: by worktop (Postfix, from userid 1000) id 59EFB6E07D5; Sun, 11 Nov 2018 00:20:59 +0100 (CET) Date: Sun, 11 Nov 2018 00:20:59 +0100 From: Peter Zijlstra To: Ard Biesheuvel Cc: Ingo Molnar , Josh Poimboeuf , Linux Kernel Mailing List , the arch/x86 maintainers , Andy Lutomirski , Steven Rostedt , Thomas Gleixner , Linus Torvalds , Masami Hiramatsu , Jason Baron , Jiri Kosina , David Laight , Borislav Petkov Subject: Re: [PATCH RFC 0/3] Static calls Message-ID: <20181110232059.GA12766@worktop.psav.com> References: <20181109072811.GB86700@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.22.1 (2013-10-16) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 09, 2018 at 02:50:27PM +0100, Ard Biesheuvel wrote: > On 9 November 2018 at 08:28, Ingo Molnar wrote: > >> - I'm not sure about the objtool approach. Objtool is (currently) > >> x86-64 only, which means we have to use the "unoptimized" version > >> everywhere else. I may experiment with a GCC plugin instead. > > > > I'd prefer the objtool approach. It's a pretty reliable first-principles > > approach while GCC plugin would have to be replicated for Clang and any > > other compilers, etc. > > > > I implemented the GCC plugin approach here for arm64 I'm confused; I though we only needed objtool for variable instruction length architectures, because we can't reliably decode our instruction stream. Otherwise we can fairly trivially use the DWARF relocation data, no?