Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp300393ybi; Thu, 1 Aug 2019 19:23:39 -0700 (PDT) X-Google-Smtp-Source: APXvYqxSAay9qcj4OqinSz+ufRwyRae6IoivZXyLmi3qRg1I+hMpPFsEZd0aGgxb0r7re15UZf34 X-Received: by 2002:a62:cdc3:: with SMTP id o186mr57457244pfg.168.1564712619231; Thu, 01 Aug 2019 19:23:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564712619; cv=none; d=google.com; s=arc-20160816; b=oSRM+UHk3/TW3+z3e3gV2IesD29HVhwtHrT0cIEHz4EL4XN3YV8R4qieHqCwcje2GS kQxbv2Antc0FOb8y06Zfg/FTa6phaqm0pBoDbfwPDv27VcOYos+w7T+PhOLcJTLVkDWj /Fc+8uzUPUj2JXEAf3+z2OOOFxBpCU4eq64vIVtYMh7jiBVatkgUXvs76jCTzapnWiGO r+qLVzlNsv+2j85+Fjl1mW0X73ITBDTZSxePIMtIXv4KcQPaP9w7VlY541wldsp+f+x+ cFYt3MhaOAbc6swexSPBnzF7E1fNRKhhgS23ebjky74qdjg86LQOyAXAiBP6maWOi4Eg 6gRQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date; bh=O1w8eb0mn93FB59dWERpHbx4UbFSu4t+CmwLDQcdoY4=; b=NrhylPItU7FreRuu42ttdU3ud0dD6idbDmXV/437w0CrR2albjE5YcerP4LzAvMEJO CHqNR3MtFpXB8m55eCyEhe3pO6n12EuOsQQwrqKWxL7ArUmjUqhi79lioCaDY5Hne+D2 ofJFlsE+ayrE6hvF6Z167SQ05ONR6/SWxSvR03av7l9Hax4hMHc+DQ9Yzt4+McvvR4AL PZrChtPUyvetuvzP56kOTNTsA63lTZK0vOX+6soAuoHHDxa1R9R7S4CGlO0der0bWiJO Kpp16whYaKcN7cY7c2PDQfdY7coAwu59o8lQNvqnrb+yRiGnXDYXkFyQBn3aMT39ibic NkoQ== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r41si5816149pjb.11.2019.08.01.19.23.22; Thu, 01 Aug 2019 19:23:39 -0700 (PDT) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389222AbfHAV7w (ORCPT + 99 others); Thu, 1 Aug 2019 17:59:52 -0400 Received: from Galois.linutronix.de ([193.142.43.55]:37995 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726403AbfHAV7v (ORCPT ); Thu, 1 Aug 2019 17:59:51 -0400 Received: from pd9ef1cb8.dip0.t-ipconnect.de ([217.239.28.184] helo=nanos) by Galois.linutronix.de with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1htJ6w-0003CC-Kb; Thu, 01 Aug 2019 23:59:46 +0200 Date: Thu, 1 Aug 2019 23:59:45 +0200 (CEST) From: Thomas Gleixner To: Peter Zijlstra cc: "Lendacky, Thomas" , "linux-kernel@vger.kernel.org" , "x86@kernel.org" , Ingo Molnar , Borislav Petkov , Arnaldo Carvalho de Melo , Alexander Shishkin , Namhyung Kim , Jiri Olsa , Jerry Hoemann Subject: Re: [PATCH] perf/x86/amd: Change NMI latency mitigation to use a timestamp In-Reply-To: <20190801214813.GB2332@hirez.programming.kicks-ass.net> Message-ID: References: <833ee307989ac6bfb45efe823c5eca4b2b80c7cf.1564685848.git.thomas.lendacky@amd.com> <20190801211613.GB3578@hirez.programming.kicks-ass.net> <20190801214813.GB2332@hirez.programming.kicks-ass.net> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 1 Aug 2019, Peter Zijlstra wrote: > On Thu, Aug 01, 2019 at 11:34:23PM +0200, Thomas Gleixner wrote: > > Avoid the whole NMI mess, make the PMC interrupt a proper vector in the > > highest prio bucket and instead of using CLI/STI use CR8. That would have > > the additional advantage that we could prevent perf "NMI" then occsionally :) > > Exactly, and not only the PMC, we can basically start giving out actual > vectors on register_nmi_handler() and do away with all that shared line > crap. > > And then the actual NMI line will be mostly empty again, and it can read > its stupid slow reason port again. > > One complication though; IRET et al only do EFLAGS, not CR8, so that's > going to be massive fun :-( > > Did I say I hates the x86 interrupt scheme? You're not alone. That stuff definitely violates article 3 of the Convention for the Protection of Human Rights and Fundamental Freedoms.