[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201110185958.GC850433@cmpxchg.org>
Date: Tue, 10 Nov 2020 13:59:58 -0500
From: Johannes Weiner <hannes@...xchg.org>
To: Alex Shi <alex.shi@...ux.alibaba.com>
Cc: akpm@...ux-foundation.org, mgorman@...hsingularity.net,
tj@...nel.org, hughd@...gle.com, khlebnikov@...dex-team.ru,
daniel.m.jordan@...cle.com, willy@...radead.org, lkp@...el.com,
linux-mm@...ck.org, linux-kernel@...r.kernel.org,
cgroups@...r.kernel.org, shakeelb@...gle.com,
iamjoonsoo.kim@....com, richard.weiyang@...il.com,
kirill@...temov.name, alexander.duyck@...il.com,
rong.a.chen@...el.com, mhocko@...e.com, vdavydov.dev@...il.com,
shy828301@...il.com,
Alexander Duyck <alexander.h.duyck@...ux.intel.com>,
Thomas Gleixner <tglx@...utronix.de>,
Andrey Ryabinin <aryabinin@...tuozzo.com>
Subject: Re: [PATCH v21 18/19] mm/lru: introduce the relock_page_lruvec
function
On Fri, Nov 06, 2020 at 03:50:22PM +0800, Alex Shi wrote:
> From 6c142eb582e7d0dbf473572ad092eca07ab75221 Mon Sep 17 00:00:00 2001
> From: Alexander Duyck <alexander.h.duyck@...ux.intel.com>
> Date: Tue, 26 May 2020 17:31:15 +0800
> Subject: [PATCH v21 18/19] mm/lru: introduce the relock_page_lruvec function
>
> Use this new function to replace repeated same code, no func change.
>
> When testing for relock we can avoid the need for RCU locking if we simply
> compare the page pgdat and memcg pointers versus those that the lruvec is
> holding. By doing this we can avoid the extra pointer walks and accesses of
> the memory cgroup.
>
> In addition we can avoid the checks entirely if lruvec is currently NULL.
>
> Signed-off-by: Alexander Duyck <alexander.h.duyck@...ux.intel.com>
> Signed-off-by: Alex Shi <alex.shi@...ux.alibaba.com>
> Acked-by: Hugh Dickins <hughd@...gle.com>
> Acked-by: Johannes Weiner <hannes@...xchg.org>
> Cc: Johannes Weiner <hannes@...xchg.org>
> Cc: Andrew Morton <akpm@...ux-foundation.org>
> Cc: Thomas Gleixner <tglx@...utronix.de>
> Cc: Andrey Ryabinin <aryabinin@...tuozzo.com>
> Cc: Matthew Wilcox <willy@...radead.org>
> Cc: Mel Gorman <mgorman@...hsingularity.net>
> Cc: Konstantin Khlebnikov <khlebnikov@...dex-team.ru>
> Cc: Hugh Dickins <hughd@...gle.com>
> Cc: Tejun Heo <tj@...nel.org>
> Cc: linux-kernel@...r.kernel.org
> Cc: cgroups@...r.kernel.org
> Cc: linux-mm@...ck.org
Acked-by: Johannes Weiner <hannes@...xchg.org>
Powered by blists - more mailing lists