kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] Use static_call for kvm_pmu_ops
@ 2021-11-03  7:03 Like Xu
  2021-11-03  7:03 ` [PATCH 1/3] KVM: x86: Copy kvm_pmu_ops by value to eliminate layer of indirection Like Xu
                   ` (2 more replies)
  0 siblings, 3 replies; 13+ messages in thread
From: Like Xu @ 2021-11-03  7:03 UTC (permalink / raw)
  To: Paolo Bonzini
  Cc: Sean Christopherson, Vitaly Kuznetsov, Wanpeng Li, Jim Mattson,
	Joerg Roedel, Thomas Gleixner, Ingo Molnar, Borislav Petkov, kvm,
	linux-kernel

Hi,

This is a successor to a previous patch set from Jason Baron. Let's convert
kvm_pmu_ops to use static_call. Shows good performance gains for
a typical perf use case [2] in the guest (results in patch 3/3).

[1] https://lore.kernel.org/lkml/cover.1610680941.git.jbaron@akamai.com/
[2] perf record -e branch-instructions -e branch-misses \
-e cache-misses -e cache-references -e cpu-cycles \
-e instructions ./workload

Thanks,

Like Xu (3):
  KVM: x86: Copy kvm_pmu_ops by value to eliminate layer of indirection
  KVM: x86: Introduce definitions to support static calls for
    kvm_pmu_ops
  KVM: x86: Use static calls to reduce kvm_pmu_ops overhead

 arch/x86/include/asm/kvm-x86-pmu-ops.h | 32 ++++++++++++++++++
 arch/x86/kvm/pmu.c                     | 46 +++++++++++++++-----------
 arch/x86/kvm/pmu.h                     | 19 ++++++++++-
 arch/x86/kvm/vmx/nested.c              |  2 +-
 arch/x86/kvm/x86.c                     |  5 +++
 5 files changed, 83 insertions(+), 21 deletions(-)
 create mode 100644 arch/x86/include/asm/kvm-x86-pmu-ops.h

-- 
2.33.0


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

end of thread, other threads:[~2021-11-08 15:42 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-03  7:03 [PATCH 0/3] Use static_call for kvm_pmu_ops Like Xu
2021-11-03  7:03 ` [PATCH 1/3] KVM: x86: Copy kvm_pmu_ops by value to eliminate layer of indirection Like Xu
2021-11-05 15:30   ` Sean Christopherson
2021-11-05 15:36     ` Sean Christopherson
2021-11-08  9:26       ` Like Xu
2021-11-08  9:23     ` Like Xu
2021-11-03  7:03 ` [PATCH 2/3] KVM: x86: Introduce definitions to support static calls for kvm_pmu_ops Like Xu
2021-11-05 15:48   ` Sean Christopherson
2021-11-08  9:31     ` Like Xu
2021-11-08 15:41       ` Sean Christopherson
2021-11-03  7:03 ` [PATCH 3/3] KVM: x86: Use static calls to reduce kvm_pmu_ops overhead Like Xu
2021-11-03 12:08   ` Yao Yuan
2021-11-04  8:14     ` Like Xu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).