1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-23 11:18:54 +00:00
freebsd/sys/vm
Alan Cox 13458803f4 Give vm_fault()'s sequential access optimization a makeover.
There are two aspects to the sequential access optimization: (1) read ahead
of pages that are expected to be accessed in the near future and (2) unmap
and cache behind of pages that are not expected to be accessed again.  This
revision changes both aspects.

The read ahead optimization is now more effective.  It starts with the same
initial read window as before, but arithmetically grows the window on
sequential page faults.  This can yield increased read bandwidth.  For
example, on one of my machines, a program using mmap() to read a file that
is several times larger than the machine's physical memory takes about 17%
less time to complete.

The unmap and cache behind optimization is now more selectively applied.
The read ahead window must grow to its maximum size before unmap and cache
behind is performed.  This significantly reduces the number of times that
pages are unmapped and cached only to be reactivated a short time later.

The unmap and cache behind optimization now clears each page's referenced
flag.  Previously, in the case of dirty pages, if the containing file was
still mapped at the time that the page daemon examined the dirty pages,
they would be reactivated.

From a stylistic standpoint, this revision also cleanly separates the
implementation of the read ahead and unmap/cache behind optimizations.

Glanced at:	kib
MFC after:	2 weeks
2012-05-10 15:16:42 +00:00
..
default_pager.c
device_pager.c
memguard.c
memguard.h
phys_pager.c
pmap.h
redzone.c
redzone.h
sg_pager.c
swap_pager.c Remove direct access to si_name. 2012-02-10 12:35:57 +00:00
swap_pager.h
uma_core.c exclude kmem_alloc'ed ARC data buffers from kernel minidumps on amd64 2012-01-27 20:18:31 +00:00
uma_dbg.c
uma_dbg.h
uma_int.h
uma.h exclude kmem_alloc'ed ARC data buffers from kernel minidumps on amd64 2012-01-27 20:18:31 +00:00
vm_contig.c In vm_object_page_clean(), do not clean OBJ_MIGHTBEDIRTY object flag 2012-03-17 23:00:32 +00:00
vm_extern.h
vm_fault.c Give vm_fault()'s sequential access optimization a makeover. 2012-05-10 15:16:42 +00:00
vm_glue.c Move kstack_cache_entry into the private header, and make the 2011-12-16 10:56:16 +00:00
vm_init.c
vm_kern.c Simplify kmem_alloc() by eliminating code that existed on account of 2012-02-29 05:41:29 +00:00
vm_kern.h
vm_map.c Give vm_fault()'s sequential access optimization a makeover. 2012-05-10 15:16:42 +00:00
vm_map.h Give vm_fault()'s sequential access optimization a makeover. 2012-05-10 15:16:42 +00:00
vm_meter.c
vm_mmap.c When MAP_STACK mapping is created, the map entry is created only to 2012-04-21 18:36:53 +00:00
vm_object.c Fix madvise(MADV_WILLNEED) to properly handle individual mappings larger 2012-03-19 18:47:34 +00:00
vm_object.h Fix madvise(MADV_WILLNEED) to properly handle individual mappings larger 2012-03-19 18:47:34 +00:00
vm_page.c Avoid a lock order reversal in pmap_extract_and_hold() from relocking 2012-04-22 17:58:30 +00:00
vm_page.h Fix mincore(2) so that it reports PG_CACHED pages as resident. 2012-04-08 18:25:12 +00:00
vm_pageout.c In vm_object_page_clean(), do not clean OBJ_MIGHTBEDIRTY object flag 2012-03-17 23:00:32 +00:00
vm_pageout.h In vm_object_page_clean(), do not clean OBJ_MIGHTBEDIRTY object flag 2012-03-17 23:00:32 +00:00
vm_pager.c
vm_pager.h
vm_param.h
vm_phys.c Bah, just revert my earlier change entirely. (Missed alc's request to do 2012-03-19 19:06:40 +00:00
vm_phys.h
vm_reserv.c If a page belonging a reservation is cached, then mark the reservation so 2012-04-08 17:00:46 +00:00
vm_reserv.h
vm_unix.c
vm_zeroidle.c
vm.h
vnode_pager.c Keep track of the mount point associated with a special device 2012-03-28 20:49:11 +00:00
vnode_pager.h Account the writeable shared mappings backed by file in the vnode 2012-02-23 21:07:16 +00:00