[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20231107183346.GA3789583@cmpxchg.org>
Date: Tue, 7 Nov 2023 13:33:46 -0500
From: Johannes Weiner <hannes@...xchg.org>
To: Hyeongtak Ji <hyeongtak.ji@...il.com>
Cc: akpm@...ux-foundation.org, linux-mm@...ck.org,
linux-kernel@...r.kernel.org, Hyeongtak Ji <hyeongtak.ji@...com>
Subject: Re: [PATCH] mm/vmscan: consider previously reclaimed pages in
shrink_lruvec()
On Mon, Aug 07, 2023 at 07:01:16PM +0900, Hyeongtak Ji wrote:
> shrink_lruvec() currently ignores previously reclaimed pages in
> scan_control->nr_reclaimed. This can lead shrink_lruvec() to reclaiming
> more pages than expected.
>
> This patch fixes shrink_lruvec() to take into account the previously
> reclaimed pages.
Do you run into real world issues from this? The code has been like
this for at least a decade.
It's an intentional choice to ensure fairness across all visited
cgroups. sc->nr_to_reclaim is 32 pages or less - it's only to guard
against extreme overreclaim. But we want to make sure we reclaim a bit
from all cgroups, rather than always hit the first one and then bail.
Powered by blists - more mailing lists