[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aBlgH4CAsO9oYXAo@google.com>
Date: Mon, 5 May 2025 18:04:31 -0700
From: Sean Christopherson <seanjc@...gle.com>
To: Borislav Petkov <bp@...en8.de>
Cc: Pavel Machek <pavel@...x.de>, Sasha Levin <sashal@...nel.org>, linux-kernel@...r.kernel.org,
stable@...r.kernel.org, Max Grobecker <max@...becker.info>, Ingo Molnar <mingo@...nel.org>,
tglx@...utronix.de, mingo@...hat.com, dave.hansen@...ux.intel.com,
x86@...nel.org, thomas.lendacky@....com, perry.yuan@....com,
mario.limonciello@....com, riel@...riel.com, mjguzik@...il.com,
darwi@...utronix.de, Paolo Bonzini <pbonzini@...hat.com>
Subject: Re: CONFIG_X86_HYPERVISOR (was: Re: [PATCH AUTOSEL 5.10 2/6] x86/cpu:
Don't clear X86_FEATURE_LAHF_LM flag in init_amd_k8() on AMD when running in
a virtual machine)
On Sat, Apr 26, 2025, Borislav Petkov wrote:
> On April 26, 2025 3:08:29 AM GMT+03:00, Sean Christopherson <seanjc@...gle.com> wrote:
> >No, that would defeat the purpose of the check. The X86_FEATURE_HYPERVISOR has
> >nothing to do with correctness, it's all about performance. Critically, it's a
> >static check that gets patched at runtime. It's a micro-optimization for bare
> >metal to avoid a single cache miss (the __this_cpu_read(cpu_dr7)). Routing
> >through cc_platform_has() would be far, far heavier than calling hw_breakpoint_active().
>
> Huh, we care so much about speed here?
That's a PeterZ question :-)
Powered by blists - more mailing lists