Re: [RFC PATCH v3 46/59] KVM: VMX: Move register caching logic to common code

From: Paolo Bonzini
Date: Mon Nov 29 2021 - 17:49:34 EST


On 11/29/21 19:23, Sean Christopherson wrote:
Only one generation of CPU, Nehalem, supports EPT but not
unrestricted guest, and disabling unrestricted guest without also
disabling EPT is, to put it bluntly, dumb.
This one is only significantly better and lacks an explanation what this
means for the dumb case.
Well, it means a retpoline (see paragraph before).

No, the point being made is that, on a CPU that supports Unrestricted Guest (UG),
disabling UG without disabling EPT is really, really stupid.

Yes, I understand that.

Thomas was asking what it means to "Move register caching logic to common code", i.e. what the consequences are. The missing words at the end of the first paragraph didn't make the connection obvious between the extra retpoline and the "dumb case".

Paolo