Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mm,vmacache: count number of system-wide flushes

These flushes deal with sequence number overflows, such as for long lived
threads. These are rare, but interesting from a debugging PoV. As such,
display the number of flushes when vmacache debugging is enabled.

Signed-off-by: Davidlohr Bueso <dbueso@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Davidlohr Bueso and committed by
Linus Torvalds
f5f302e2 16a7ade8

+4
+1
include/linux/vm_event_item.h
··· 90 90 #ifdef CONFIG_DEBUG_VM_VMACACHE 91 91 VMACACHE_FIND_CALLS, 92 92 VMACACHE_FIND_HITS, 93 + VMACACHE_FULL_FLUSHES, 93 94 #endif 94 95 NR_VM_EVENT_ITEMS 95 96 };
+2
mm/vmacache.c
··· 17 17 { 18 18 struct task_struct *g, *p; 19 19 20 + count_vm_vmacache_event(VMACACHE_FULL_FLUSHES); 21 + 20 22 /* 21 23 * Single threaded tasks need not iterate the entire 22 24 * list of process. We can avoid the flushing as well
+1
mm/vmstat.c
··· 900 900 #ifdef CONFIG_DEBUG_VM_VMACACHE 901 901 "vmacache_find_calls", 902 902 "vmacache_find_hits", 903 + "vmacache_full_flushes", 903 904 #endif 904 905 #endif /* CONFIG_VM_EVENTS_COUNTERS */ 905 906 };