Re: [RFC PATCH V2 4/4] Utilize the vmx preemption timer for tsc deadline timer

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 26/05/2016 16:05, Alan Jenkins wrote:
> 1. Against my interests: have you actually confirmed the VMX preemption
> timer is affected by guest TSC scaling?

No, it's not, hence my formula:

    host_tsc = ((unsigned __int128)(guest_tsc - tsc_offset)
            << kvm_tsc_scaling_ratio_frac_bits)
            / vcpu->arch.tsc_scaling_ratio;

The idea is that once you have a host TSC deadline, you can use it to
set the preemption timer on vmentry.

>    It's not explicit in the SDM.  The way it's described for allocating
> timeslices to the guest, IMO it makes more sense if it is not scaled.
> 
> 2. Paolo, any chance I could also get away with requiring 64-bit?  I.e.
> 
> #ifdef CONFIG_X86_64
> #define HAVE_LAPIC_TIMER_ADVANCE 1
> #endif

I wouldn't object.

Paolo
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux