Re: [PATCH] mm: Add AnonZero accounting for zero-filled anonymous pages
From: Matthew Wilcox
Date: Mon Feb 16 2026 - 09:27:26 EST
On Sat, Feb 14, 2026 at 04:45:14PM +0800, Wenchao Hao wrote:
> Add kernel command line option "count_zero_page" to track anonymous pages
> have been allocated and mapped to userspace but zero-filled.
>
> This feature is mainly used to debug large folio mechanism, which
> pre-allocates and map more pages than actually needed, leading to memory
> waste from unaccessed pages.
Why are you trying to get this upstream when you admitted in an earlier
email this is just for your internal use?
Why do you think that "unaccessed pages" are the only, or even the
largest source of extra memory consumption? The vast majority of files
are never mmaped.
This just seems like a giant waste of time.