lkml.org 
[lkml]   [2022]   [Aug]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: Should Linux set the new constant-time mode CPU flags?
From
On 8/29/22 09:39, Jason A. Donenfeld wrote:
> On Thu, Aug 25, 2022 at 11:15:58PM +0000, Eric Biggers wrote:
>> I'm wondering if people are aware of this issue, and whether anyone has any
>> thoughts on whether/where the kernel should be setting these new CPU flags.
>> There don't appear to have been any prior discussions about this. (Thanks to
> Maybe it should be set unconditionally now, until we figure out how to
> make it more granular.

Personally, I'm in this camp as well. Let's be safe and set it by
default. There's also this tidbit in the Intel docs (and chopping out a
bunch of the noise):

(On) processors based on microarchitectures before Ice Lake ...
the instructions listed here operate as if DOITM is enabled.

IOW, setting DOITM=0 isn't going back to the stone age. At worst, I'd
guess that you're giving up some optimization that only shows up in very
recent CPUs in the first place.

If folks want DOITM=1 on their snazzy new CPUs, then they came come with
performance data to demonstrate the gain they'll get from adding kernel
code to get DOITM=1. There are a range of ways we could handle it, all
the way from adding a command-line parameter to per-task management.

Anybody disagree?

\
 
 \ /
  Last update: 2022-08-30 16:25    [W:0.115 / U:0.324 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site