Thread (41 messages) 41 messages, 5 authors, 2021-02-10

Re: [RFC][PATCH 11/13] mm/vmscan: Consider anonymous pages without swap

From: Yang Shi <hidden>
Date: 2021-02-02 22:37:20
Also in: lkml

On Tue, Feb 2, 2021 at 1:35 PM Dave Hansen [off-list ref] wrote:
On 2/2/21 10:56 AM, Yang Shi wrote:
quoted
quoted
        /* If we have no swap space, do not bother scanning anon pages. */
-       if (!sc->may_swap || mem_cgroup_get_nr_swap_pages(memcg) <= 0) {
+       if (!sc->may_swap || !can_reclaim_anon_pages(memcg, pgdat->node_id)) {
Just one minor thing about may_swap. It may be cleared by
nr_boost_reclaim. But demotion should be fine for boost_reclaim.
In other words, this if() is here is to avoid generating suboptimal I/O
during boost_reclaim.  But, since demotion doesn't generate any I/O, it
*should* be fine for boost_reclaim.

I agree with that in theory.  Although, I'm tempted to put it in the
TODO list as something to look at in the future.  Do you think it's
something that's immediately necessary?
No, I don't think so. We could tweak this later on.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help