freebsd-dev/sys/vm
Konstantin Belousov 77d6fd97ef Improve vm_object_scan_all_shadowed() to also check swap backing objects.
As noted in the removed comment, it is possible and not prohibitively
costly to look up the swap blocks for the given page index.  Implement
a swap_pager_find_least() function to do that, and use it to iterate
simultaneously over both backing object page queue and swap
allocations when looking for shadowed pages.

Testing shows that number of new succesful scans, enabled by this
addition, is small but non-zero.  When worked out, the change both
further reduces the depth of the shadow object chain, and frees unused
but allocated swap and memory.

Suggested and reviewed by:	alc
Tested by:	pho (previous version)
Sponsored by:	The FreeBSD Foundation
MFC after:	2 weeks
2016-12-18 20:56:14 +00:00
..
_vm_radix.h During vm_page_cache()'s call to vm_radix_insert(), if vm_page_alloc() was 2016-12-01 17:26:37 +00:00
default_pager.c Provide introductory description of the default pager. 2016-12-14 23:36:32 +00:00
device_pager.c Add a new populate() pager method and extend device pager ops vector 2016-12-08 11:26:11 +00:00
memguard.c
memguard.h
phys_pager.c Implement the populate() pager method for phys pager. 2016-12-08 11:35:53 +00:00
pmap.h Various changes to pmap_ts_referenced() 2016-09-10 16:49:25 +00:00
redzone.c
redzone.h
sg_pager.c
swap_pager.c Improve vm_object_scan_all_shadowed() to also check swap backing objects. 2016-12-18 20:56:14 +00:00
swap_pager.h Improve vm_object_scan_all_shadowed() to also check swap backing objects. 2016-12-18 20:56:14 +00:00
uma_core.c Simplify keg_drain() a bit by using LIST_FOREACH_SAFE. 2016-10-20 23:10:27 +00:00
uma_dbg.c
uma_dbg.h
uma_int.h
uma.h
vm_domain.c
vm_domain.h
vm_extern.h
vm_fault.c Add a new populate() pager method and extend device pager ops vector 2016-12-08 11:26:11 +00:00
vm_glue.c Eliminate unneeded vm_page_xbusy() and vm_page_xunbusy() operations when 2016-08-14 22:00:45 +00:00
vm_init.c Conditionally move initial vfs bio alloc above 4G 2016-10-03 13:23:43 +00:00
vm_kern.c
vm_kern.h
vm_map.c Use db_lookup_proc() in the DDB 'show procvm' command. 2016-12-13 19:22:43 +00:00
vm_map.h
vm_meter.c Conditionalize PG_CACHE sysctls on COMPAT_FREEBSD11. 2016-12-09 18:55:27 +00:00
vm_mmap.c Remove most of the code for implementing PG_CACHED pages. (This change does 2016-11-15 18:22:50 +00:00
vm_object.c Improve vm_object_scan_all_shadowed() to also check swap backing objects. 2016-12-18 20:56:14 +00:00
vm_object.h Eliminate every mention of PG_CACHED pages from the comments in the machine- 2016-12-12 17:47:09 +00:00
vm_page.c Eliminate every mention of PG_CACHED pages from the comments in the machine- 2016-12-12 17:47:09 +00:00
vm_page.h Eliminate every mention of PG_CACHED pages from the comments in the machine- 2016-12-12 17:47:09 +00:00
vm_pageout.c Release laundered vnode pages to the head of the inactive queue. 2016-11-23 17:53:07 +00:00
vm_pageout.h
vm_pager.c Allow bogus_page to be passed to pager(s). 2016-12-09 21:21:24 +00:00
vm_pager.h Add a new populate() pager method and extend device pager ops vector 2016-12-08 11:26:11 +00:00
vm_param.h
vm_phys.c Remove support for idle page zeroing. 2016-09-03 20:38:13 +00:00
vm_phys.h Remove support for idle page zeroing. 2016-09-03 20:38:13 +00:00
vm_radix.c Previously, vm_radix_remove() would panic if the radix trie didn't 2016-12-08 04:29:29 +00:00
vm_radix.h Previously, vm_radix_remove() would panic if the radix trie didn't 2016-12-08 04:29:29 +00:00
vm_reserv.c Eliminate every mention of PG_CACHED pages from the comments in the machine- 2016-12-12 17:47:09 +00:00
vm_reserv.h Remove most of the code for implementing PG_CACHED pages. (This change does 2016-11-15 18:22:50 +00:00
vm_unix.c
vm.h
vnode_pager.c Release laundered vnode pages to the head of the inactive queue. 2016-11-23 17:53:07 +00:00
vnode_pager.h