Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1513659
| From | Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH v7 10/11] x86, xen: support vcpu preempted check |
| Date | 2016-11-02 06:20 +0100 |
| Message-ID | <syW7U-1Vz-39@gated-at.bofh.it> (permalink) |
| References | <syW7T-1Vz-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
From: Juergen Gross <jgross@suse.com> Support the vcpu_is_preempted() functionality under Xen. This will enhance lock performance on overcommitted hosts (more runnable vcpus than physical cpus in the system) as doing busy waits for preempted vcpus will hurt system performance far worse than early yielding. A quick test (4 vcpus on 1 physical cpu doing a parallel build job with "make -j 8") reduced system time by about 5% with this patch. Signed-off-by: Juergen Gross <jgross@suse.com> Signed-off-by: Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> --- arch/x86/xen/spinlock.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/x86/xen/spinlock.c b/arch/x86/xen/spinlock.c index 3d6e006..74756bb 100644 --- a/arch/x86/xen/spinlock.c +++ b/arch/x86/xen/spinlock.c @@ -114,7 +114,6 @@ void xen_uninit_lock_cpu(int cpu) per_cpu(irq_name, cpu) = NULL; } - /* * Our init of PV spinlocks is split in two init functions due to us * using paravirt patching and jump labels patching and having to do @@ -137,6 +136,8 @@ void __init xen_init_spinlocks(void) pv_lock_ops.queued_spin_unlock = PV_CALLEE_SAVE(__pv_queued_spin_unlock); pv_lock_ops.wait = xen_qlock_wait; pv_lock_ops.kick = xen_qlock_kick; + + pv_lock_ops.vcpu_is_preempted = xen_vcpu_stolen; } /* -- 2.4.11
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH v7 00/11] implement vcpu preempted check Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> - 2016-11-02 06:20 +0100 [PATCH v7 11/11] Documentation: virtual: kvm: Support vcpu preempted check Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> - 2016-11-02 06:20 +0100 [PATCH v7 04/11] powerpc/spinlock: support vcpu preempted check Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> - 2016-11-02 06:20 +0100 [PATCH v7 01/11] kernel/sched: introduce vcpu preempted check interface Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> - 2016-11-02 06:20 +0100 [PATCH v7 08/11] x86, kvm/x86.c: support vcpu preempted check Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> - 2016-11-02 06:20 +0100 [PATCH v7 02/11] locking/osq: Drop the overload of osq_lock() Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> - 2016-11-02 06:20 +0100 [PATCH v7 06/11] x86, paravirt: Add interface to support kvm/xen vcpu preempted check Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> - 2016-11-02 06:20 +0100 [PATCH v7 05/11] s390/spinlock: Provide vcpu_is_preempted Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> - 2016-11-02 06:20 +0100 [PATCH v7 10/11] x86, xen: support vcpu preempted check Pan Xinhui <xinhui.pan@linux.vnet.ibm.com> - 2016-11-02 06:20 +0100
csiph-web