KVM: optimize memslots searching
Get series with b4
b4 am [email protected]Versions newest first
- v2 Latest6 patches 16 repliesIn review
Change log from the cover letter
- sort memslots base on its size and do the line search instead of binary search base on gfn, it is from Avi's idea.
- in order to reduce cache footprint, memslots are sorted in the array of kvm->memslots->memslots[] and introduce a table to map slot id to index in the array
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | KVM: introduce KVM_MEM_SLOTS_NUM macroarch/ arch/ include/ +1 more | +10 | 0 replies | |
| 2/6 | KVM: introduce update_memslots functionarch/ include/ virt/ | +17 | 0 replies | |
| 3/6 | KVM: introduce kvm_for_each_memslot macroarch/ arch/ include/ +2 more | +20 | 6 replies | |
| 4/6 | KVM: introduce id_to_memslot functionarch/ arch/ arch/ +3 more | +25 | 0 replies | |
| 5/6 | KVM: sort memslots by its size and use line searchinclude/ virt/ | +75 | 3 replies | |
| 6/6 | KVM: introduce a table to map slot id to index in memslots arryinclude/ virt/ | +13 | 2 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH v2 0/6] KVM: optimize memslots searching
This is the more work base on my v1 patchset which is posted some months ago, it can be found at:
https://lkml.org/lkml/2011/2/22/68
Change log:
- sort memslots base on its size and do the line search instead of binary search base on gfn, it is from Avi's idea.
- in order to reduce cache footprint, memslots are sorted in the array of kvm->memslots->memslots[] and introduce a table to map slot id to index in the array
There is the performance result:
autotest for RHEL.6.1 setup/boot/reboot/shutdown(average):
ept=1: before: 449.5 after: 447.8
ept=0: before: 532.7 after: 529.8
kernbench(average):
ept=1: before: 127.94 after: 126.98
ept=0: before: 196.85 after: 189.66