[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Yk6UQrjqSQnePdxe@dhcp22.suse.cz>
Date: Thu, 7 Apr 2022 09:35:30 +0200
From: Michal Hocko <mhocko@...e.com>
To: "Huang, Ying" <ying.huang@...el.com>
Cc: Wei Xu <weixugc@...gle.com>, Yosry Ahmed <yosryahmed@...gle.com>,
Johannes Weiner <hannes@...xchg.org>,
Shakeel Butt <shakeelb@...gle.com>,
Andrew Morton <akpm@...ux-foundation.org>,
David Rientjes <rientjes@...gle.com>,
Tejun Heo <tj@...nel.org>, Zefan Li <lizefan.x@...edance.com>,
Roman Gushchin <roman.gushchin@...ux.dev>,
Cgroups <cgroups@...r.kernel.org>,
"open list:DOCUMENTATION" <linux-doc@...r.kernel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Linux MM <linux-mm@...ck.org>,
Jonathan Corbet <corbet@....net>, Yu Zhao <yuzhao@...gle.com>,
Dave Hansen <dave.hansen@...ux.intel.com>,
Greg Thelen <gthelen@...gle.com>,
Tim Chen <tim.c.chen@...ux.intel.com>
Subject: Re: [PATCH resend] memcg: introduce per-memcg reclaim interface
On Wed 06-04-22 14:32:24, Huang, Ying wrote:
[...]
> I think we should define the interface not from the current
> implementation point of view, but from the requirement point of view.
Agreed!
> For proactive reclaim, per my understanding, the requirement is,
>
> we found that there's some cold pages in some workloads, so we can
> take advantage of the proactive reclaim to reclaim some pages so that
> other workload can use the freed memory.
We are talking about memcg here so this is not as much a matter of free
memory as it is to decrease the amount of charged memory. Demotion
cannot achieve that.
> For proactive demotion, per my understanding, the requirement could be,
>
> We found that there's some cold pages in fast memory (e.g. DRAM) in
> some workloads, so we can take advantage of the proactive demotion to
> demote some pages so that other workload can use the freed fast
> memory. Given the DRAM partition support Tim (Cced) is working on.
Yes, this is essentially a kernel assisted memory migration. Userspace
can migrate memory but the issue is that it doesn't have any information
on the aging so the migration has hard time to find suitable memory to
migrate. If we really need this functionality then it would deserve a
separate interface IMHO.
--
Michal Hocko
SUSE Labs
Powered by blists - more mailing lists