DragonFly BSD
DragonFly commits List (threaded) for 2010-01
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

git: kernel - simplify vm pager ops, add pre-faulting for zero-fill pages.


From: Matthew Dillon <dillon@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Sun, 17 Jan 2010 18:01:20 -0800 (PST)

commit 1b9d3514e66df9d4bc5a25c898c7c8cbe414e3e4
Author: Matthew Dillon <dillon@apollo.backplane.com>
Date:   Sun Jan 17 17:27:50 2010 -0800

    kernel - simplify vm pager ops, add pre-faulting for zero-fill pages.
    
    * Remove the behind and ahead arguments to struct pagerops->pgo_getpages,
      and pagerops->pgo_haspage.
    
      Adjust pgo_getpages() to pgo_getpage(), change *_pager_getpages() to
      *_pager_getpage(), etc.  Add a sequential access flag to the call.
    
      The VM system is no longer responsible for dealing with read-ahead on
      pager ops.  The individual pagers are now responsible.
    
      The vnode pager now specifies the sequential access heuristic based on
      the hint passed to it.  HAMMER uses this hint to issue readaheads via
      the buffer cache.
    
    * Move, rename, and consolidate pmap_prefault().  Remove this function
      from all platform sources and place it in vm/vm_fault.c.  Add a
      simple platform-specific pmap_prefault_ok() function to test particular
      virtual addresses.
    
    * The new prefault code is called vm_prefault().  Enhance the code to
      also prefault and make writable (when it can) zero-fill pages.
    
      The new zero-fill prefault feature improves buildworld times by
      over 5% by greatly reducing the number of VM faults taken during
      normal program operation.  This particularly helps larger applications
      and concurrent applications in SMP systems.
    
      The code is conditionalized such that small applications (which do not
      benefit much from prefaulting zero-fill) still run about as fast as
      they did before.
    
    * Fix an issue in vm_fault() where the vm_map was being unlocked before
      the prefault code was called when it really needs to be unlocked
      after the prefault code is called.

Summary of changes:
 sys/kern/kern_exec.c                 |   32 +---
 sys/platform/pc32/i386/pmap.c        |  115 ++---------
 sys/platform/pc32/i386/trap.c        |   17 +-
 sys/platform/pc64/x86_64/pmap.c      |  116 ++---------
 sys/platform/pc64/x86_64/trap.c      |   16 +-
 sys/platform/vkernel/i386/trap.c     |   16 +-
 sys/platform/vkernel/platform/pmap.c |  127 ++----------
 sys/vm/default_pager.c               |   12 +-
 sys/vm/device_pager.c                |   39 ++---
 sys/vm/phys_pager.c                  |   46 ++---
 sys/vm/pmap.h                        |    3 +-
 sys/vm/swap_pager.c                  |   32 ++--
 sys/vm/swap_pager.h                  |    2 +-
 sys/vm/vm_fault.c                    |  373 ++++++++++++++++++++++++----------
 sys/vm/vm_map.h                      |    2 +-
 sys/vm/vm_object.c                   |   10 +-
 sys/vm/vm_pager.c                    |   14 +-
 sys/vm/vm_pager.h                    |   44 ++---
 sys/vm/vnode_pager.c                 |   55 ++----
 19 files changed, 457 insertions(+), 614 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/1b9d3514e66df9d4bc5a25c898c7c8cbe414e3e4


-- 
DragonFly BSD source repository



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]