linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Shakeel Butt <shakeel.butt@linux.dev>
To: jingxiang zeng <jingxiangzeng.cas@gmail.com>
Cc: Jingxiang Zeng <linuszeng@tencent.com>,
	linux-mm@kvack.org,  Johannes Weiner <hannes@cmpxchg.org>,
	Michal Hocko <mhocko@kernel.org>,
	 Roman Gushchin <roman.gushchin@linux.dev>,
	Muchun Song <muchun.song@linux.dev>,
	 Andrew Morton <akpm@linux-foundation.org>,
	cgroups@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mm/memcontrol: add per-memcg pgpgin/pswpin counter
Date: Fri, 13 Sep 2024 09:58:26 -0700	[thread overview]
Message-ID: <idy4zi4d5xk2sk7qxczmkdnxw35bohr6o5exj6oeee4lipm3dk@pbw35acxapov> (raw)
In-Reply-To: <CAJqJ8ig2=UqSTemAEU_5Shtc_S=deEuHyq1fJ1QUi1PU=_8pCQ@mail.gmail.com>

On Fri, Sep 13, 2024 at 04:05:51PM GMT, jingxiang zeng wrote:
> On Tue, 10 Sept 2024 at 15:10, Shakeel Butt <shakeel.butt@linux.dev> wrote:
> >
> > On Fri, Aug 30, 2024 at 04:22:44PM GMT, Jingxiang Zeng wrote:
> > > From: Jingxiang Zeng <linuszeng@tencent.com>
> > >
> > > In proactive memory reclamation scenarios, it is necessary to
> > > estimate the pswpin and pswpout metrics of the cgroup to
> > > determine whether to continue reclaiming anonymous pages in
> > > the current batch. This patch will collect these metrics and
> > > expose them.
> >
> > Please explain a bit more on how these metrics will be used to make
> > a decision to continue to do proactive reclaim or not.
> 
> Currently there is simply no way to know exactly how many anon page
> was faulted in through SWAP for each cgroup. One may use
> workingset refault as an indicator but it is inaccurate due to shadow reclaim.
> 
> We have a proactive reclaim agent that sets a forced swappiness
> dynamically for each reclaim, so we can reclaim file or anon pages striclty.
> Knowing the anon page swapin status is a huge win for estimating the
> workload status.
> 
> And the swapout info is also important for getting an idea of how much
> swapout is effective for a cgroup.
> 

Please add all these details on your proactive reclaim agent in the
commit message. It would be beneficial to others doing proactive
reclaim.



      reply	other threads:[~2024-09-13 16:58 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-30  8:22 Jingxiang Zeng
2024-09-09 22:29 ` Andrew Morton
2024-09-09 22:45 ` Yosry Ahmed
2024-09-10  5:28   ` jingxiang zeng
2024-09-10  7:08 ` Shakeel Butt
2024-09-13  8:05   ` jingxiang zeng
2024-09-13 16:58     ` Shakeel Butt [this message]

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=idy4zi4d5xk2sk7qxczmkdnxw35bohr6o5exj6oeee4lipm3dk@pbw35acxapov \
    --to=shakeel.butt@linux.dev \
    --cc=akpm@linux-foundation.org \
    --cc=cgroups@vger.kernel.org \
    --cc=hannes@cmpxchg.org \
    --cc=jingxiangzeng.cas@gmail.com \
    --cc=linuszeng@tencent.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mhocko@kernel.org \
    --cc=muchun.song@linux.dev \
    --cc=roman.gushchin@linux.dev \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox