]> www.infradead.org Git - users/jedix/linux-maple.git/commit
vmstat: add pcp remote node draining via cpu_vm_stats_fold
authorMarcelo Tosatti <mtosatti@redhat.com>
Mon, 20 Mar 2023 18:03:45 +0000 (15:03 -0300)
committerAndrew Morton <akpm@linux-foundation.org>
Tue, 28 Mar 2023 23:25:10 +0000 (16:25 -0700)
commit5189f7aeea5e4408988e343f24c6ea1139129461
tree11af2837aac48ba20f18d08eb3f95bc5a3c3576d
parent0db1595e4cd30c688fd060af3e8399815509b8bb
vmstat: add pcp remote node draining via cpu_vm_stats_fold

Large NUMA systems might have significant portions of system memory to be
trapped in pcp queues.  The number of pcp is determined by the number of
processors and nodes in a system.  A system with 4 processors and 2 nodes
has 8 pcps which is okay.  But a system with 1024 processors and 512 nodes
has 512k pcps with a high potential for large amount of memory being
caught in them.

Enable remote node draining for the CONFIG_HAVE_CMPXCHG_LOCAL case, where
vmstat_shepherd will perform the aging and draining via cpu_vm_stats_fold.

Link: https://lkml.kernel.org/r/20230320180745.858515310@redhat.com
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Suggested-by: Vlastimil Babka <vbabka@suse.cz>
Cc: Aaron Tomlin <atomlin@atomlin.com>
Cc: Christoph Lameter <cl@linux.com>
Cc: Frederic Weisbecker <frederic@kernel.org>
Cc: Heiko Carstens <hca@linux.ibm.com>
Cc: Huacai Chen <chenhuacai@kernel.org>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Peter Xu <peterx@redhat.com>
Cc: "Russell King (Oracle)" <linux@armlinux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/vmstat.h
mm/page_alloc.c
mm/vmstat.c