Re: [PATCH RFC 1/2] KVM: don't check for PF_VCPU when yielding

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

 



> This change is a trade-off.
> PRO: This patch would improve the case of preemption on s390. This is probably a corner case as most distros have preemption off anyway.
> CON: The downside is that kvm_vcpu_yield_to is called also from kvm_vcpu_on_spin. Here we want to avoid the scheduler overhead for a wrong decision.   

Won't most of that part be covered by:
	if (!ACCESS_ONCE(vcpu->preempted))

vcpu->preempted is only set when scheduled out involuntarily. It is cleared
when scheduled in. s390 sets it manually, to speed up waking up a vcpu.

So when our task is scheduled in (an PF_VCPU is set), this check will already
avoid scheduler overhead in kvm_vcpu_on_spin() or am I missing something?

--
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