[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZZeu6DwVt6o0fl14@memverge.com>
Date: Fri, 5 Jan 2024 02:25:28 -0500
From: Gregory Price <gregory.price@...verge.com>
To: "Huang, Ying" <ying.huang@...el.com>
Cc: Gregory Price <gourry.memverge@...il.com>, linux-mm@...ck.org,
linux-doc@...r.kernel.org, linux-fsdevel@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-api@...r.kernel.org,
x86@...nel.org, akpm@...ux-foundation.org, arnd@...db.de,
tglx@...utronix.de, luto@...nel.org, mingo@...hat.com, bp@...en8.de,
dave.hansen@...ux.intel.com, hpa@...or.com, mhocko@...nel.org,
tj@...nel.org, corbet@....net, rakie.kim@...com,
hyeongtak.ji@...com, honggyu.kim@...com, vtavarespetr@...ron.com,
peterz@...radead.org, jgroves@...ron.com, ravis.opensrc@...ron.com,
sthanneeru@...ron.com, emirakhur@...ron.com, Hasan.Maruf@....com,
seungjun.ha@...sung.com,
Srinivasulu Thanneeru <sthanneeru.opensrc@...ron.com>
Subject: Re: [PATCH v5 02/11] mm/mempolicy: introduce
MPOL_WEIGHTED_INTERLEAVE for weighted interleaving
On Fri, Jan 05, 2024 at 02:51:40PM +0800, Huang, Ying wrote:
> >
> > So we're talking ~1MB for 1024 threads with mempolicies to avoid error
> > conditions mid-page-allocation and to reduce the cost associated with
> > applying weighted interleave.
>
> Think about this again. Why do we need weights array on stack? I think
> this is used to keep weights consistent. If so, we don't need weights
> array on stack. Just use RCU to access global weights array.
>
>From the bulk allocation code:
__alloc_pages_bulk(gfp, node, NULL, node_pages, NULL, page_array);
This function can block. You cannot block during an RCU read context.
~Gregory
Powered by blists - more mailing lists