Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1248438 > unrolled thread
| Started by | Takuya Yoshikawa <yoshikawa_takuya_b1@lab.ntt.co.jp> |
|---|---|
| First post | 2015-10-16 10:00 +0200 |
| Last post | 2015-10-16 10:30 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH 0/5 v2] KVM: x86: MMU: Eliminate extra memory slot searches in page fault handlers Takuya Yoshikawa <yoshikawa_takuya_b1@lab.ntt.co.jp> - 2015-10-16 10:00 +0200
Re: [PATCH 0/5 v2] KVM: x86: MMU: Eliminate extra memory slot searches in page fault handlers Paolo Bonzini <pbonzini@redhat.com> - 2015-10-16 10:30 +0200
| From | Takuya Yoshikawa <yoshikawa_takuya_b1@lab.ntt.co.jp> |
|---|---|
| Date | 2015-10-16 10:00 +0200 |
| Subject | [PATCH 0/5 v2] KVM: x86: MMU: Eliminate extra memory slot searches in page fault handlers |
| Message-ID | <qk85H-8iu-3@gated-at.bofh.it> |
v2: Based on Paolo's suggestion, kept the common code as much as possible by
introducing memslot_valid_for_gpte().
Note: instead of joining all checks by boolean operators, splitted the
no_dirty_log case off to be a separate if-check because it is checking
clearly different thing than the rest. See patch 4 for details.
In page fault handlers, both mapping_level_dirty_bitmap() and mapping_level()
do a memory slot search, binary search, through kvm_vcpu_gfn_to_memslot(), which
may not be negligible especially for virtual machines with many memory slots.
With a bit of cleanup effort, the patch set reduces this overhead.
Takuya
Takuya Yoshikawa (5):
KVM: x86: MMU: Make force_pt_level bool
KVM: x86: MMU: Simplify force_pt_level calculation code in FNAME(page_fault)()
KVM: x86: MMU: Merge mapping_level_dirty_bitmap() into mapping_level()
KVM: x86: MMU: Remove mapping_level_dirty_bitmap()
KVM: x86: MMU: Eliminate an extra memory slot search in mapping_level()
arch/x86/kvm/mmu.c | 70 +++++++++++++++++++++++++++-------------------
arch/x86/kvm/paging_tmpl.h | 19 ++++++-------
2 files changed, 50 insertions(+), 39 deletions(-)
--
2.1.0
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Paolo Bonzini <pbonzini@redhat.com> |
|---|---|
| Date | 2015-10-16 10:30 +0200 |
| Subject | Re: [PATCH 0/5 v2] KVM: x86: MMU: Eliminate extra memory slot searches in page fault handlers |
| Message-ID | <qk8yK-FP-3@gated-at.bofh.it> |
| In reply to | #1248438 |
On 16/10/2015 10:03, Takuya Yoshikawa wrote: > v2: Based on Paolo's suggestion, kept the common code as much as possible by > introducing memslot_valid_for_gpte(). > > Note: instead of joining all checks by boolean operators, splitted the > no_dirty_log case off to be a separate if-check because it is checking > clearly different thing than the rest. See patch 4 for details. Of course that's better. Series applied, thanks. Paolo -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web