Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp35825iog; Tue, 28 Jun 2022 14:18:55 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tg9E1rPjx1DBTBcieYRFc2WjbKki5RtHJg+HLe1PA102K7l308kCSurn9aHlb/OOLCUa0F X-Received: by 2002:a17:902:ce85:b0:16a:4637:c4da with SMTP id f5-20020a170902ce8500b0016a4637c4damr7071923plg.82.1656451134771; Tue, 28 Jun 2022 14:18:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656451134; cv=none; d=google.com; s=arc-20160816; b=kvvkUERyXC5gBT2Kps91I8ILXXZuLRHWuUbRJxGZQz+5dtldfDZjd5LDUFqGX+lu01 vAu0HrHRxz6q4phHKZVwIyMr70UH1caPs97lOIGo5ovJcyOAiaaR7UCpnDw4+r6PSpO5 MYX7e+5Vuy/Rmn30yqDL6HGu/z6/fNiKLhh8k9wTflzUbLd75iFOGIEKwbA3FCFElFpT z8jDULvdv46xUkcgR45PFkhcDTpFOK+vW+3BU7XekzX52PcIiEjRRrXplhUzuVx7nFDS jNI0FumEEPxfmfWVps7jkX7JDg16uttGei0vLq36gE9sj94N+M8eWseNe3TaLZ9OtaQ9 +b9A== 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:dkim-signature; bh=9tDe52GGxzPcMmdw3mYkuOmIyW05Nrirch7vLV731MU=; b=ztg7VpPzDDQ5qBQDhr/HNVdQsqEMfKIberbZIzOh7kHjXbhjGsUgt1uwtZ1UhKKCgU 3NN/FV+puWvdbubsRHl7ZSD0HMOCTiJIyRbYC4nTmqUD1som7xdjdDW/wUv+TkJlWVHU nZrkSh83gG3DipszDdKYGDBhap2kTwU20VvSqIvKKkeTP3chaf/QHhj+EeG8DyHtVHHx v29ky9s8zSiYZBjDG8rYZrbg5kf3hUgvUfNtbqSBOoIvVK2e+9XaT29PD092//7f9lax lZem3pwTGhJZ3WsSI8d9FVBlMtItsQd5wSVS9bQ4v20QF7mPA4XbfdZxRixIwE5ZKMZc YYtQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ljimGrfw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g63-20020a636b42000000b003fe3d4af87asi736708pgc.655.2022.06.28.14.17.52; Tue, 28 Jun 2022 14:18:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ljimGrfw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230183AbiF1VQg (ORCPT + 99 others); Tue, 28 Jun 2022 17:16:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58420 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229509AbiF1VQe (ORCPT ); Tue, 28 Jun 2022 17:16:34 -0400 Received: from mail-yw1-x112c.google.com (mail-yw1-x112c.google.com [IPv6:2607:f8b0:4864:20::112c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E7DE53192A for ; Tue, 28 Jun 2022 14:16:32 -0700 (PDT) Received: by mail-yw1-x112c.google.com with SMTP id 00721157ae682-3176d94c236so130428237b3.3 for ; Tue, 28 Jun 2022 14:16:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=9tDe52GGxzPcMmdw3mYkuOmIyW05Nrirch7vLV731MU=; b=ljimGrfwxm5aduRgvJ1pepWTHcFxjaYSqtMuTkTWyjsLXWTlNz6xomYBkx1fap/1Fz qS8dDnrrWxY3MG3d1mIwuS47Xawi2WwcyElxjPReaRIL8ZV5zWidTLmkfo/ujoVGssRN /xsqxr59B4wRpDdgvBn/GQqpXCva/Yt4wMguNchxEVtnpSMOdvU+D5GkDB9kvH2oqLnz mYfIbvJKlSA6kOq2I4Pa1ny1gdS/5PDmwr0GfsJX7sSfhmMVZTLMPbnHRa4rTJOG5jft DNFUJ1KKOABN5BFrwE0k5F40J5+zHDxJ1iXN9FDtI4TvdLEi0sHrUH5soI2fJcx9esd1 ta0Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=9tDe52GGxzPcMmdw3mYkuOmIyW05Nrirch7vLV731MU=; b=XnTpUkRNcqFgfok/eepRJnPUFSLiU6Qq4A86zRZB0rf/g81Ymmrr52wE1yVXgtzHlY hIRJwi7ZxwGnCU7Vg72pXhj0NkAMtlmVnuUNlLonSzOzefR4fPu/EFiDSyHVcG8w0pdW OgICMT//HZsSrWptul04E724wD3m6eTuMwYM4TRg2uyggb5ynoBPgy9mp4tda9Srps/6 MdahUUTDKFdKeGUTXn+a7KiJdwCqIYbCXEGQ7hYpNhDvQUIzgJ+qHJyh9QjqHclkWKc0 7J87mBJLiuiF+p8Axr5dzbUaP+/e+Sv0GKu13ebhCZmmOiXdkMZ94lV9W3FdJSu8SqW9 F0YQ== X-Gm-Message-State: AJIora8gZ29Yy9KViLsdXY4b5i9zPo+rzocSapb5zx7RWpHqpk1L2tCi wEZpwDuEtCCqoa1uDt34e785ja5+mykBUH/JjlrLNQ== X-Received: by 2002:a0d:e20a:0:b0:317:ce36:a3a0 with SMTP id l10-20020a0de20a000000b00317ce36a3a0mr120718ywe.448.1656450991969; Tue, 28 Jun 2022 14:16:31 -0700 (PDT) MIME-Version: 1.0 References: <20220607120530.2447112-1-tarumizu.kohei@fujitsu.com> <086370dd-281f-5ac6-3a0f-f1b80500c668@intel.com> <6934b82d-db12-8a17-7dea-7bcbd4fe8566@intel.com> In-Reply-To: <6934b82d-db12-8a17-7dea-7bcbd4fe8566@intel.com> From: Linus Walleij Date: Tue, 28 Jun 2022 23:17:22 +0200 Message-ID: Subject: Re: [PATCH v5 0/6] Add hardware prefetch control driver for A64FX and x86 To: Dave Hansen Cc: "tarumizu.kohei@fujitsu.com" , Greg KH , "catalin.marinas@arm.com" , "will@kernel.org" , "tglx@linutronix.de" , "mingo@redhat.com" , "bp@alien8.de" , "dave.hansen@linux.intel.com" , "x86@kernel.org" , "hpa@zytor.com" , "rafael@kernel.org" , "lenb@kernel.org" , "mchehab+huawei@kernel.org" , "eugenis@google.com" , "tony.luck@intel.com" , "pcc@google.com" , "peterz@infradead.org" , "marcos@orca.pet" , "marcan@marcan.st" , "nicolas.ferre@microchip.com" , "conor.dooley@microchip.com" , "arnd@arndb.de" , "ast@kernel.org" , "peter.chen@kernel.org" , "kuba@kernel.org" , "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-acpi@vger.kernel.org" , Paolo Valente , Andrew Morton Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 28, 2022 at 11:02 PM Dave Hansen wrote: > On 6/28/22 13:20, Linus Walleij wrote: > > > > Well if the knobs are exposed to userspace, how do people using > > these knobs know when to turn them? A profiler? perf? All that > > data is available to the kernel too. > > They run their fortran app. Change the MSRs. Run it again. See if it > simulated the nuclear weapon blast any faster or slower. Rinse. Repeat. That sounds like a schoolbook definition of the trial-and-error method. https://en.wikipedia.org/wiki/Trial_and_error That's fair. But these people really need a better hammer. > This interface would take a good chunk of the x86 wrmsr(1) audience and > convert them over to a less dangerous interface. That's a win on x86. > We don't even *remotely* have line-of-sight for a generic solution for > the kernel to figure out a single "best" value for these registers. Maybe less dangerous for them, but maybe more dangerous for the kernel community who signs up to maintain the behaviour of that interface perpetually. Yours, Linus Walleij