All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH 0/3] kvm: x86: speedups for APICv
@ 2016-09-27 21:20 Paolo Bonzini
  2016-09-27 21:20 ` [PATCH 1/3] kvm: x86: avoid atomic operations on APICv vmentry Paolo Bonzini
                   ` (3 more replies)
  0 siblings, 4 replies; 29+ messages in thread
From: Paolo Bonzini @ 2016-09-27 21:20 UTC (permalink / raw)
  To: linux-kernel, kvm; +Cc: yang.zhang.wz, feng.wu, mst, rkrcmar

These patches save 40 cycles on kvm-unit-tests "inl" tests, but I suspect
the effect is bigger on workloads that inject interrupts heavily.

The difficult one is patch 2.  I find the new code easier to follow than
the old one, but it doesn't mean it works. :)  The aim is for APICv to
not use KVM_REQ_EVENT at all for interrupts, therefore turning APICv's
weakness (having to look at PIR on every vmentry) into a strength
(because checking PIR.ON is cheaper than processing KVM_REQ_EVENT).
The others are just micro-optimization of the surrounding code.

Tested extremely lightly and obviously not for 4.9, just shooting it
out now.

Paolo

Paolo Bonzini (3):
  kvm: x86: avoid atomic operations on APICv vmentry
  kvm: x86: do not use KVM_REQ_EVENT for APICv interrupt injection
  KVM: x86: do not scan IRR twice on APICv vmentry

 arch/x86/include/asm/kvm_host.h |  2 +-
 arch/x86/kvm/lapic.c            | 31 +++++++++++++++++++------------
 arch/x86/kvm/lapic.h            |  4 ++--
 arch/x86/kvm/svm.c              |  2 +-
 arch/x86/kvm/vmx.c              | 30 ++++++++++++++++++------------
 arch/x86/kvm/x86.c              | 16 ++++++++++------
 6 files changed, 51 insertions(+), 34 deletions(-)

-- 
1.8.3.1

^ permalink raw reply	[flat|nested] 29+ messages in thread

end of thread, other threads:[~2016-10-14  8:12 UTC | newest]

Thread overview: 29+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-27 21:20 [RFC PATCH 0/3] kvm: x86: speedups for APICv Paolo Bonzini
2016-09-27 21:20 ` [PATCH 1/3] kvm: x86: avoid atomic operations on APICv vmentry Paolo Bonzini
2016-09-27 21:20 ` [PATCH 2/3] kvm: x86: do not use KVM_REQ_EVENT for APICv interrupt injection Paolo Bonzini
2016-09-27 23:07   ` Michael S. Tsirkin
2016-09-28  8:21     ` Paolo Bonzini
2016-09-28 11:40       ` Wu, Feng
2016-09-28 11:50         ` Paolo Bonzini
2016-09-28 12:06           ` Wu, Feng
2016-09-28 12:14             ` Paolo Bonzini
2016-10-14  7:37           ` Yang Zhang
2016-10-14  8:12             ` Paolo Bonzini
2016-09-28 13:46       ` Michael S. Tsirkin
2016-09-28 14:08         ` Paolo Bonzini
2016-09-28 10:04   ` Wu, Feng
2016-09-28 10:16     ` Paolo Bonzini
2016-09-28 11:53       ` Wu, Feng
2016-09-28 11:55         ` Paolo Bonzini
2016-09-28 12:07           ` Wu, Feng
2016-10-14  7:12   ` Yang Zhang
2016-09-27 21:20 ` [PATCH 3/3] KVM: x86: do not scan IRR twice on APICv vmentry Paolo Bonzini
2016-09-28 14:00   ` Michael S. Tsirkin
2016-09-28 14:44     ` Paolo Bonzini
2016-09-29  2:51   ` Wu, Feng
2016-10-14  7:32   ` Yang Zhang
2016-10-14  7:45     ` Paolo Bonzini
2016-09-29 19:55 ` [RFC PATCH 0/3] kvm: x86: speedups for APICv Radim Krčmář
2016-09-29 21:41   ` Paolo Bonzini
2016-09-30 13:23     ` Radim Krčmář
2016-09-30 13:33     ` Radim Krčmář

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.