[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20211126165211.GL3366@techsingularity.net>
Date: Fri, 26 Nov 2021 16:52:11 +0000
From: Mel Gorman <mgorman@...hsingularity.net>
To: Alexey Avramov <hakavlad@...ox.lv>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Michal Hocko <mhocko@...e.com>,
Vlastimil Babka <vbabka@...e.cz>,
Rik van Riel <riel@...riel.com>,
Mike Galbraith <efault@....de>,
Darrick Wong <djwong@...nel.org>, regressions@...ts.linux.dev,
Linux-fsdevel <linux-fsdevel@...r.kernel.org>,
Linux-MM <linux-mm@...ck.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 1/1] mm: vmscan: Reduce throttling due to a failure to
make progress
On Sat, Nov 27, 2021 at 01:12:46AM +0900, Alexey Avramov wrote:
> >After the patch, the test gets killed after roughly 15 seconds which is
> >the same length of time taken in 5.15.
>
> In my tests, the 5.15 still performs much better.
>
How much better?
> New question: is timeout=1 has sense? Will it save CPU?
It's the minimum stall time available -- it's 1 tick so the exact stall
time depends on HZ and yes, it's to stall to wait for something to
happen. It'll get woken early if another reclaimer makes forward progress.
This patch on top will stall less. I sent it already but it may not be
clear that I meant it to be applied on top of this patch.
diff --git a/mm/vmscan.c b/mm/vmscan.c
index 176ddd28df21..167ea4f324a8 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -3404,8 +3404,8 @@ static void consider_reclaim_throttle(pg_data_t *pgdat, struct scan_control *sc)
if (current_is_kswapd())
return;
- /* Throttle if making no progress at high prioities. */
- if (sc->priority < DEF_PRIORITY - 2 && !sc->nr_reclaimed)
+ /* Throttle if making no progress at high priority. */
+ if (sc->priority == 1 && !sc->nr_reclaimed)
reclaim_throttle(pgdat, VMSCAN_THROTTLE_NOPROGRESS);
}
--
Mel Gorman
SUSE Labs
Powered by blists - more mailing lists