All of lore.kernel.org
 help / color / mirror / Atom feed
From: SeongJae Park <sjpark@amazon.com>
To: David Rientjes <rientjes@google.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Yang Shi <shy828301@gmail.com>, Michal Hocko <mhocko@kernel.org>,
	Shakeel Butt <shakeelb@google.com>,
	"Yang Shi" <yang.shi@linux.alibaba.com>,
	Roman Gushchin <guro@fb.com>, Greg Thelen <gthelen@google.com>,
	Johannes Weiner <hannes@cmpxchg.org>,
	Vladimir Davydov <vdavydov.dev@gmail.com>,
	<cgroups@vger.kernel.org>, <linux-mm@kvack.org>
Subject: Re: Re: [patch] mm, memcg: provide a stat to describe reclaimable memory
Date: Wed, 15 Jul 2020 09:15:22 +0200	[thread overview]
Message-ID: <20200715071522.19663-1-sjpark@amazon.com> (raw)
In-Reply-To: <alpine.DEB.2.23.453.2007142353350.2694999@chino.kir.corp.google.com> (raw)

Hello David,

On Wed, 15 Jul 2020 00:00:03 -0700 (PDT) David Rientjes <rientjes@google.com> 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


WARNING: multiple messages have this Message-ID (diff)
From: SeongJae Park <sjpark-vV1OtcyAfmbQT0dZR+AlfA@public.gmane.org>
To: David Rientjes <rientjes-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>
Cc: Andrew Morton
	<akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org>,
	Yang Shi <shy828301-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	Michal Hocko <mhocko-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	Shakeel Butt <shakeelb-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>,
	Yang Shi
	<yang.shi-KPsoFbNs7GizrGE5bRqYAgC/G2K4zDHf@public.gmane.org>,
	Roman Gushchin <guro-b10kYP2dOMg@public.gmane.org>,
	Greg Thelen <gthelen-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>,
	Johannes Weiner <hannes-druUgvl0LCNAfugRpC6u6w@public.gmane.org>,
	Vladimir Davydov
	<vdavydov.dev-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org
Subject: Re: Re: [patch] mm, memcg: provide a stat to describe reclaimable memory
Date: Wed, 15 Jul 2020 09:15:22 +0200	[thread overview]
Message-ID: <20200715071522.19663-1-sjpark@amazon.com> (raw)
In-Reply-To: <alpine.DEB.2.23.453.2007142353350.2694999-X6Q0R45D7oAcqpCFd4KODRPsWskHk0ljAL8bYrjMMd8@public.gmane.org> (raw)

Hello David,

On Wed, 15 Jul 2020 00:00:03 -0700 (PDT) David Rientjes <rientjes-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org> 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

  reply	other threads:[~2020-07-15  7:16 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-15  3:18 [patch] mm, memcg: provide a stat to describe reclaimable memory David Rientjes
2020-07-15  3:18 ` David Rientjes
2020-07-15  7:00 ` David Rientjes
2020-07-15  7:00   ` David Rientjes
2020-07-15  7:15   ` SeongJae Park [this message]
2020-07-15  7:15     ` SeongJae Park
2020-07-15 17:33     ` David Rientjes
2020-07-15 17:33       ` David Rientjes
2020-07-16 20:58       ` [patch] mm, memcg: provide an anon_reclaimable stat David Rientjes
2020-07-16 20:58         ` David Rientjes
2020-07-16 21:07         ` Shakeel Butt
2020-07-16 21:07           ` Shakeel Butt
2020-07-16 21:28           ` David Rientjes
2020-07-16 21:28             ` David Rientjes
2020-07-17  1:37             ` Shakeel Butt
2020-07-17  1:37               ` Shakeel Butt
2020-07-17  8:34         ` Michal Hocko
2020-07-17  8:34           ` Michal Hocko
2020-07-17 14:39         ` Johannes Weiner
2020-07-17 14:39           ` Johannes Weiner
2020-07-15 13:10 ` [patch] mm, memcg: provide a stat to describe reclaimable memory Chris Down
2020-07-15 13:10   ` Chris Down
     [not found]   ` <20200715131048.GA176092-6Bi1550iOqEnzZ6mRAm98g@public.gmane.org>
2020-07-15 18:02     ` David Rientjes
2020-07-17 12:17       ` Chris Down
2020-07-17 12:17         ` Chris Down
2020-07-17 19:37         ` David Rientjes
2020-07-17 19:37           ` David Rientjes
2020-07-20  7:37           ` Michal Hocko
2020-07-20  7:37             ` Michal Hocko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200715071522.19663-1-sjpark@amazon.com \
    --to=sjpark@amazon.com \
    --cc=akpm@linux-foundation.org \
    --cc=cgroups@vger.kernel.org \
    --cc=gthelen@google.com \
    --cc=guro@fb.com \
    --cc=hannes@cmpxchg.org \
    --cc=linux-mm@kvack.org \
    --cc=mhocko@kernel.org \
    --cc=rientjes@google.com \
    --cc=shakeelb@google.com \
    --cc=shy828301@gmail.com \
    --cc=vdavydov.dev@gmail.com \
    --cc=yang.shi@linux.alibaba.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.