Re: Turning on DOITM at last

From: Dave Hansen

Date: Mon Jul 20 2026 - 08:33:15 EST


On 7/18/26 10:01, Demi Marie Obenour wrote:
> Is it time to go ahead and turn on DOITM?

No, I don't think so.

> - If it doesn't do anything, it's a harmless no-op.

I kinda disagree with this.

There are CPUs that enumerate support for DOITM but on which it doesn't
do anything. On those CPUs, every cycle spent twiddling it is a waste.

> - If it does something, then that something needed to be done to
> protect code that handles secrets, such as crypto code.

I really disagree with this.

Lots of code "handles secrets". memcpy() "handles secrets".

> - The overhead of switching it on and off is too high, so it's best
> to just leave it on all the time.

The overhead *is* too high. It's an MSR bit that requires a user/kernel
round trip.

> - Even people who don't care about speculative execution
> vulnerabilities, because they only run trusted code on a particular
> server, still likely need secure cryptography.

I'm not sure where speculative execution vulnerabilities came in to play
here.

> Xen already turned it on in the past.

While I very much respect the Xen folks and their security posture, Xen
is a very different project than Linux.