From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.linutronix.de (146.0.238.70:993) by crypto-ml.lab.linutronix.de with IMAP4-SSL for ; 09 Feb 2019 04:34:10 -0000 Received: from mga14.intel.com ([192.55.52.115]) by Galois.linutronix.de with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1gsKLB-0004vm-A2 for speck@linutronix.de; Sat, 09 Feb 2019 05:34:09 +0100 Date: Fri, 8 Feb 2019 20:34:06 -0800 From: Andi Kleen Subject: [MODERATED] Re: [RFC][PATCH] performance walnuts Message-ID: <20190209043406.GD16922@tassilo.jf.intel.com> References: <3dd5d6e2bc9ac53f826c251c68ce84fcc79a6872.1549582769.git.ak@linux.intel.com> <20190208090147.GK32477@hirez.programming.kicks-ass.net> <20190208093950.GD32534@hirez.programming.kicks-ass.net> <20190208105318.GE32534@hirez.programming.kicks-ass.net> MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit To: speck@linutronix.de List-ID: On Fri, Feb 08, 2019 at 04:28:41PM -0800, speck for Linus Torvalds wrote: > On Fri, Feb 8, 2019 at 2:53 AM speck for Peter Zijlstra > wrote: > > > > +static void intel_set_tfa(struct cpu_hw_events *cpuc, bool on) > > +{ > > + u64 val = MSR_TFA_RTM_FORCE_ABORT * on; > > Have you actually verified that this does the right thing on all > versions of gcc? > > In particular, I certainly hope it doesn't cause an actual multiply instruction. On Skylake IMUL is 3 cycles latency so it should be fine in any case. -Andi