ååï[RFC] Question about async TLB flush and KVM pv tlb improvements

From: äåå(éé)
Date: Tue Feb 25 2020 - 02:26:12 EST


>> On Feb 24, 2020, at 8:12 PM, äåå(éé) <bangcai.hrg@xxxxxxxxxxxxxxx> wrote:
>>
>> Hi there,
>>
>> I saw this async TLB flush patch at
>> https://lore.kernel.org/patchwork/patch/1082481/ , and I am wondering
>> after one year, do you think if this patch is practical or there are
>> functional flaws? From my POV, Nadav's patch seems has no obvious flaw.
>> But I am not familiar about the relationship between CPU's speculation
>> exec and stale TLB, since it's usually transparent from programing. In
>> which condition would machine check occurs? Is there some reference I can
>> learn?

> I was/am held back by personal issues that consume my free time, which
> prevented me from sending a new version so far.

Good to hear that :)

> As for the patch-set - the greatest benefit in performance comes from
> running local/remote TLB flushes concurrently, and I will respin another
> version of that in two weeks time. I will send the async flushes afterwards.

In non-overcommitment virtualization environment, I think this will be
beneficial. Since the async implementation still need remote CPUâs IPI
response, pv tlb flush can address this scenarioâs need.

Do you have any reference about relationship between CPU's speculation
and stale TLB, especially causing machine check? I want to learn about this,
thanks.