Re: [RFC PATCH v2 2/3] x86/mm/tlb: Defer PTI flushes

From: Dave Hansen
Date: Tue Aug 27 2019 - 14:28:55 EST

On 8/23/19 3:52 PM, Nadav Amit wrote:
> INVPCID is considerably slower than INVLPG of a single PTE. Using it to
> flush the user page-tables when PTI is enabled therefore introduces
> significant overhead.

I'm not sure this is worth all the churn, especially in the entry code.
For large flushes (> tlb_single_page_flush_ceiling), we don't do
INVPCIDs in the first place.

I'd really want to understand what the heck is going on that makes
INVPCID so slow, first.