git: kernel - Refactor vm_page_alloc() to improve hot pages

Matthew Dillon dillon at
Sun Feb 5 19:00:12 PST 2017

commit 635c9c159eb758c1328d8a014b7cb1d0255d00ab
Author: Matthew Dillon <dillon at>
Date:   Sun Feb 5 18:51:24 2017 -0800

    kernel - Refactor vm_page_alloc() to improve hot pages
    * Since we do not pre-zero pages any more, nothing uses PG_ZERO and we no
      longer have to use the head and tail of the free queue as an indication
      of a possibly freed page being zerod or not.
      For PQ_FREE, refactor the use case to always be LIFO, improving chances
      that vm_page_alloc() will retrieve a page that is already hot in the
    * Should improve the host, and in particular will improve the vkernel,
      preventing it from unnecessarily cycling new pages (faulting them in
      on the host) when normal operation is in steady-state, and also reducing
      unnecessary initial/fresh faults.

Summary of changes:
 sys/vm/vm_page.c    | 40 +++++++++++++++++-----------------------
 sys/vm/vm_page.h    |  2 +-
 sys/vm/vm_pageout.c |  3 +--
 3 files changed, 19 insertions(+), 26 deletions(-)

DragonFly BSD source repository

More information about the Commits mailing list