Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp3594330pxf; Mon, 29 Mar 2021 06:33:50 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxv6RZZtxEnXU/GzQ41AeYRhYMGZoTmSEYOVL6tJZl9ugnf4YemTQThdxih040i6tFOGT2C X-Received: by 2002:a05:6402:4244:: with SMTP id g4mr28544278edb.204.1617024829847; Mon, 29 Mar 2021 06:33:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1617024829; cv=none; d=google.com; s=arc-20160816; b=ZMd9fS2n7aaXFbttn+XOnwfaJBx1Soy83oPgfklMUA+zY1CvPpQqKSVwdyV5YPGDeq QYlLRUX6fI1ZOCkxzEgmyHHkxRETinJxgXuihVcelvLf+PInCTARr3W5TKD99SJBjgKa Q4PDnkjnz+ynWeWm4QytolvFSNnuW1Sk0//fU/xZuaa9WYc04ZTjmyLwTQskc0MBesZS onZtc8PnhN+2HEbsVZL1jOjaQ83z1VgnMXi34ceRgN2lPCtIUxGJT7iItrTdiL9A5lUs GjTUWfFrnmcty70JaqwCx/jOke0qYf41E/LIxnjCMe3OsHeuSqTUWm6YuPvurqCc2I9Q EX2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version; bh=KytxCMPWowD4rik3dQfwPYa5nzVpGWTaHqOIiMrFA+g=; b=f9YYj8hHhLgqN61j0UT7noHfqQsDtNzd7Y2rG0VuZ3/q8UAEaGBOgYM8j8y2Vs07FF EasXkaI8I6or67A1U9bJhBM2kxUholfax+aHchJXvgj7MFbLNSbuaD0oT5gj2Bt8iZbO mJ4Igwbf6fNCQDHRj4Izhx94HiBi0I/N9gcfCG8uDzhWEJIj2w+lfEySjykxLsqRpY4q vX9g1PKL7eVBytO71ZM1UbHU0izcg81VVpSbf9VhNCx6McCaDIHl0DFZCPw5FcYWcBRF q7aQjZRUZkFh0ZaIG9Twyqrj57kH5htCofT9BT65aA82L3Nwgp3/OujVAcGUKlGtCleX FRGA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k18si13082580eja.602.2021.03.29.06.33.27; Mon, 29 Mar 2021 06:33:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231649AbhC2NcL (ORCPT + 99 others); Mon, 29 Mar 2021 09:32:11 -0400 Received: from mail-ej1-f54.google.com ([209.85.218.54]:40650 "EHLO mail-ej1-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229674AbhC2Nbk (ORCPT ); Mon, 29 Mar 2021 09:31:40 -0400 Received: by mail-ej1-f54.google.com with SMTP id u9so19460390ejj.7; Mon, 29 Mar 2021 06:31:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=KytxCMPWowD4rik3dQfwPYa5nzVpGWTaHqOIiMrFA+g=; b=kuqPKtuhHfuYrJS/R3dkx8XMpToTOb8T57yjI+/gr/e2EVStSpaRJxsVBemx8pE2iW 4pQrepGTmDQ1ujQBc4N5XKVqpirWlLzbItl1mIemeoSQz9OvrykUySE1tQAvJIYE3KVS hObVR5oMAivMBDO+Lkg6q8nm5mAFcJ+qWO4ckBoauLhRZJuylE+PtiwmT7fXdkOGaSDt e7jVg0VV/0PCnchudTrxZ3tJpkOl26OjKfTxZsrQFmZcVJMiY6jhDZVixc9helz7tvO9 VAKxWAoy92yXXxu5LqEx3if42HfQiUTgzl3/MVqlAEPkm3BAmLzZ3SoYNsWEGSIkxzix ZC5Q== X-Gm-Message-State: AOAM530P5IXTau65K2mdPsClPrtwChPAWP0OY8SsdnLNKlmYRdR/3hZU IQxN3fcfl/7Pl1bSoAJvFUWxCCW4eMSVGQIgBu+VI9BF X-Received: by 2002:a17:906:4055:: with SMTP id y21mr28073275ejj.507.1617024699011; Mon, 29 Mar 2021 06:31:39 -0700 (PDT) MIME-Version: 1.0 References: <20210221185637.19281-1-chang.seok.bae@intel.com> <20210221185637.19281-23-chang.seok.bae@intel.com> <871rc9bl3v.fsf@nanos.tec.linutronix.de> <87r1k0ck7o.ffs@nanos.tec.linutronix.de> In-Reply-To: <87r1k0ck7o.ffs@nanos.tec.linutronix.de> From: Len Brown Date: Mon, 29 Mar 2021 09:31:27 -0400 Message-ID: Subject: Re: [PATCH v4 22/22] x86/fpu/xstate: Introduce boot-parameters to control state component support To: Thomas Gleixner Cc: Andy Lutomirski , "Chang S. Bae" , Borislav Petkov , Ingo Molnar , X86 ML , "Brown, Len" , Dave Hansen , "Liu, Jing2" , "Ravi V. Shankar" , Linux Kernel Mailing List , Linux Documentation List Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Mar 27, 2021 at 6:20 PM Thomas Gleixner wrote: > What's the actual downside of issuing TILERELEASE conditionally > depending on prev->AMX INIT=0? Is it slooooow or what's the real > problem here? TILERELEASE is fast, so there should be no down-side to execute it. Indeed, checking whether you need to execute it or not will probably take longer than executing TILERELEASE. My point (perhaps academic) is that Linux should not have to know about TILERELEASE, or execute it. Re: running in the kernel with AMX INIT=0 AMX INIT=0 will prevent c6 on that core. I don't expect to see this in the syscall path, though if a user wanted to neglect to issue TILERELEASE, there is nothing forcing them to do so. It can certainly happen on the interrupt path, but on the interrupt patch I don't know if we can end up requesting c6 -- perhaps on a forced task migration? Re: frequency credits in the kernel with AMX INIT=0. It works exactly the same way as AMX INIT=1. That is to say, the frequency credits don't key off of AMX INIT, they key off of the actual use of the AMX execution unit, and the credits free up several orders of magnitude faster (both for AVX-512 and AMX) on this hardware as in previous generations. As a result, if we interrupt an AMX program, and run for an extended period of time in the kernel without XRESTOR to clear out his AMX INIT=0 state, that will not have any impact on the frequency we run inside the kernel any more than if he had AMX INIT=1 state. thanks, Len Brown, Intel Open Source Technology Center