[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ac068319-a38d-4514-c075-a09b88d2d979@suse.cz>
Date: Thu, 14 Jul 2016 14:12:28 +0200
From: Vlastimil Babka <vbabka@...e.cz>
To: Mel Gorman <mgorman@...hsingularity.net>,
Andrew Morton <akpm@...ux-foundation.org>,
Linux-MM <linux-mm@...ck.org>
Cc: Rik van Riel <riel@...riel.com>,
Johannes Weiner <hannes@...xchg.org>,
Minchan Kim <minchan@...nel.org>,
Joonsoo Kim <iamjoonsoo.kim@....com>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 25/34] mm, vmscan: avoid passing in classzone_idx
unnecessarily to compaction_ready
On 07/08/2016 11:35 AM, Mel Gorman wrote:
> The scan_control structure has enough information available for
> compaction_ready() to make a decision. The classzone_idx manipulations in
> shrink_zones() are no longer necessary as the highest populated zone is
> no longer used to determine if shrink_slab should be called or not.
>
> Signed-off-by: Mel Gorman <mgorman@...hsingularity.net>
> Acked-by: Hillf Danton <hillf.zj@...baba-inc.com>
Acked-by: Vlastimil Babka <vbabka@...e.cz>
> @@ -2621,8 +2609,8 @@ static void shrink_zones(struct zonelist *zonelist, struct scan_control *sc)
> */
> if (IS_ENABLED(CONFIG_COMPACTION) &&
> sc->order > PAGE_ALLOC_COSTLY_ORDER &&
> - zonelist_zone_idx(z) <= classzone_idx &&
> - compaction_ready(zone, sc->order, classzone_idx)) {
> + zonelist_zone_idx(z) <= sc->reclaim_idx &&
Hm I notice that the condition on the line above should be always true
as the same sc->reclaim_idx value is used to limit zone_idx in
for_each_zone_zonelist_nodemask(). The implication was probably true
even before this patch (classzone_idx would be <= sc->reclaim_idx), but
now it stands out clearly.
> + compaction_ready(zone, sc)) {
> sc->compaction_ready = true;
> continue;
> }
>
Powered by blists - more mailing lists