From mboxrd@z Thu Jan 1 00:00:00 1970 From: SeongJae Park Subject: Re: Re: [patch] mm, memcg: provide a stat to describe reclaimable memory Date: Wed, 15 Jul 2020 09:15:22 +0200 Message-ID: <20200715071522.19663-1-sjpark@amazon.com> References: Mime-Version: 1.0 Return-path: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1594797369; x=1626333369; h=from:to:cc:subject:date:message-id:in-reply-to: mime-version; bh=HEw3+Ao/fqO9FvXA+Yo3+7G67lorJbwZfAa4e34wU6o=; b=FKkUZ+ixFASeTPY+2m6wAwM0YA2HW9sExpozMrc4IS3oO+zIytEYTxVC wpU5FRBncGRBUhiAI8GKnAVA4ZKnPyXxxBHbNKEho5pnIqDtedmHq559B E5uLm6OHdFZAla1czKEyzvjejFsE8NLosdLwzbR4QM3VcYxD3XKGgoGwR M=; In-Reply-To: (raw) Sender: cgroups-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-ID: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: David Rientjes Cc: Andrew Morton , Yang Shi , Michal Hocko , Shakeel Butt , Yang Shi , Roman Gushchin , Greg Thelen , Johannes Weiner , Vladimir Davydov , cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org Hello David, On Wed, 15 Jul 2020 00:00:03 -0700 (PDT) David Rientjes wrote: > On Tue, 14 Jul 2020, David Rientjes wrote: > [...] > > An alternative to this would also be to change from an "available" metric > to an "anon_reclaimable" metric since both the deferred split queues and > lazy freeable memory would pertain to anon. This would no longer attempt > to mimic MemAvailable and leave any such calculation to userspace > (anon_reclaimable + (file + slab_reclaimable) / 2). > > With this route, care would need to be taken to clearly indicate that > anon_reclaimable is not necessarily a subset of the "anon" metric since > reclaimable memory from compound pages on deferred split queues is not > mapped, so it doesn't show up in NR_ANON_MAPPED. > > I'm indifferent to either approach and would be happy to switch to > anon_reclaimable if others agree and doesn't foresee any extensibility > issues. Agreed, I was also once confused about the 'MemAvailable'. The 'reclaimable' might be better to understand. Thanks, SeongJae Park