summaryrefslogtreecommitdiffstats
path: root/arch/x86/kvm/svm/svm_ops.h
diff options
context:
space:
mode:
authorWanpeng Li <wanpengli@tencent.com>2021-04-16 11:08:10 +0800
committerPaolo Bonzini <pbonzini@redhat.com>2021-04-21 12:20:03 -0400
commit52acd22faa1af8a0514ccd075a6978ac97986425 (patch)
treef44ddca88a050d054456a436ee0de9010d5ea4fd /arch/x86/kvm/svm/svm_ops.h
parentc265878fcb2c96befe7424e984011ed0ce6d095d (diff)
downloadlinux-stable-52acd22faa1af8a0514ccd075a6978ac97986425.tar.gz
linux-stable-52acd22faa1af8a0514ccd075a6978ac97986425.tar.bz2
linux-stable-52acd22faa1af8a0514ccd075a6978ac97986425.zip
KVM: Boost vCPU candidate in user mode which is delivering interrupt
Both lock holder vCPU and IPI receiver that has halted are condidate for boost. However, the PLE handler was originally designed to deal with the lock holder preemption problem. The Intel PLE occurs when the spinlock waiter is in kernel mode. This assumption doesn't hold for IPI receiver, they can be in either kernel or user mode. the vCPU candidate in user mode will not be boosted even if they should respond to IPIs. Some benchmarks like pbzip2, swaptions etc do the TLB shootdown in kernel mode and most of the time they are running in user mode. It can lead to a large number of continuous PLE events because the IPI sender causes PLE events repeatedly until the receiver is scheduled while the receiver is not candidate for a boost. This patch boosts the vCPU candidiate in user mode which is delivery interrupt. We can observe the speed of pbzip2 improves 10% in 96 vCPUs VM in over-subscribe scenario (The host machine is 2 socket, 48 cores, 96 HTs Intel CLX box). There is no performance regression for other benchmarks like Unixbench spawn (most of the time contend read/write lock in kernel mode), ebizzy (most of the time contend read/write sem and TLB shoodtdown in kernel mode). Signed-off-by: Wanpeng Li <wanpengli@tencent.com> Message-Id: <1618542490-14756-1-git-send-email-wanpengli@tencent.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'arch/x86/kvm/svm/svm_ops.h')
0 files changed, 0 insertions, 0 deletions