kernel - Improve pmap hinting, improve performance
authorMatthew Dillon <dillon@apollo.backplane.com>
Wed, 18 Oct 2017 06:45:56 +0000 (23:45 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Wed, 18 Oct 2017 07:01:05 +0000 (00:01 -0700)
commitbb1339f814acc2e25a2e638ad85318d0567418ba
tree666e08257ab938e96b32ef85778026e079b86f83
parent845bd036cbda57cad61596e264373e0e8461a760
kernel - Improve pmap hinting, improve performance

* Refactor pm_pvhint into two fields, pm_pvhint_pt and pm_pvhint_pte.
  These are the most common hits.

* Consolidate the pv_entry lookup core into pv_entry_lookup() and
  implementing the double hinting.  Adjust pv_cache() to use the
  new fields.

* Improve pmap_object_init_pt() performance by using the new
  RB_SCAN_NOLK() code and soft-busying the VM pages instead
  of hard-busying them.  If we have to deactivate the page, however,
  we must hard-busy the page.

* Fix vm_prefault_quick() committed recently.  When soft-busying
  VM pages for pmap-entry, we have to fall-back to a hard-busy
  if the page must be moved out of PQ_CACHE.
sys/platform/pc64/include/pmap.h
sys/platform/pc64/x86_64/pmap.c
sys/vm/vm_fault.c