Re: [PATCH 23/30] x86, kaiser: use PCID feature to make user and kernel switches faster
From: Dave Hansen
Date: Thu Nov 16 2017 - 14:25:42 EST
On 11/16/2017 11:19 AM, Andrea Arcangeli wrote:
> On Fri, Nov 10, 2017 at 11:31:50AM -0800, Dave Hansen wrote:
>> Hugh Dickins also points out that PCIDs really have two distinct
>> use-cases in the context of KAISER. The first way they can be used
> I don't see why you try to retain such a minor optimization for newer
> Intel chips when at the same you prevent KAISER to run with good
> performance on older Intel chips like SandyBridge/IvyBridge which
> would create a major performance regression for those two.
This was more straightforward to do.
The other way requires having *TWO* PCID modes. So, we need to
disambiguate the two modes in the existing infrastructure in addition to
adding KAISER.
Had I gone and done that, my fear was that we would be left with no
usable PCIDs on *any* hardware. So, this was easier, I went and did it
first, and I'd love to see someone add support for PCIDs on those older
non-INVPCID systems. "Someone" may even be me, but it'll be in v2.
Patches welcome before then. :)