[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 1/2] x86/hvm: improve performance of HVMOP_flush_tlbs
On 31.12.2019 13:10, Roger Pau Monné wrote: > On Fri, Dec 27, 2019 at 02:52:17PM +0000, Andrew Cooper wrote: >> On 24/12/2019 13:26, Roger Pau Monne wrote: >>> There's no need to call paging_update_cr3 unless CR3 trapping is >>> enabled, and that's only the case when using shadow paging or when >>> requested for introspection purposes, otherwise there's no need to >>> pause all the vCPUs of the domain in order to perform the flush. >>> >>> Check whether CR3 trapping is currently in use in order to decide >>> whether the vCPUs should be paused, otherwise just perform the flush. >>> >>> Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx> >> >> I agree that the existing logic poor, but this direction looks to be >> even more fragile. >> >> Instead, I think it would be better to follow the EPT invalidation >> example; mark all vcpus as needing a tlb flush, and IPI the domain dirty >> mask, having the return-to-guest path do the flushing. > > AFAICT there's no need to call the tlb flush, the vmexit/vmentry > itself will perform the necessary flushes, so the only requirement is > to IPI the pCPUs in order to force a vmexit. TLB flushing is at best conditional upon VM entry - see the callers of hvm_asid_handle_vmenter(). Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |