lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20260107093957.12f7417670241f270783e2d1@linux-foundation.org>
Date: Wed, 7 Jan 2026 09:39:57 -0800
From: Andrew Morton <akpm@...ux-foundation.org>
To: Bing Jiao <bingjiao@...gle.com>
Cc: linux-mm@...ck.org, Johannes Weiner <hannes@...xchg.org>, David
 Hildenbrand <david@...nel.org>, Michal Hocko <mhocko@...nel.org>, Qi Zheng
 <zhengqi.arch@...edance.com>, Shakeel Butt <shakeel.butt@...ux.dev>,
 Lorenzo Stoakes <lorenzo.stoakes@...cle.com>, Axel Rasmussen
 <axelrasmussen@...gle.com>, Yuanchu Xie <yuanchu@...gle.com>, Wei Xu
 <weixugc@...gle.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1 0/2] mm/vmscan: optimize preferred target demotion
 node selection

On Wed,  7 Jan 2026 07:28:12 +0000 Bing Jiao <bingjiao@...gle.com> wrote:

> In tiered memory systems, the demotion aims to move cold folios to the
> far-tier nodes. To maintain system performance, the demotion target
> should ideally be the node with the shortest NUMA distance from the
> source node.
> 
> However, the current implementation has two suboptimal behaviors:
> 
> 1. Unbalanced Fallback: When the primary preferred demotion node is full,
>    the allocator falls back to other nodes in a way that often skews
>    toward zones that closer to the primary preferred node rather than
>    distributing the load evenly across fallback nodes.
> 
> 2. Suboptimal Target Selection: demote_folio_list() randomly select
>    a preferred node from the allowed mask, potentially selecting
>    a very distant node.
> 
> This series optimizes the selection logic while ensuring balanced
> allocation across fallback nodes.
> 
> Patch 1/2 introduces a randomized fallback mechanism in
> alloc_demote_folio() to prevent allocation hotspots when the preferred
> node is under memory pressure.
> 
> Patch 2/2 updates demote_folio_list() to traverse the demotion targets
> hierarchically, ensuring the perferred target is always the closest
> available node.

Yes, those things sound rather suboptimal.  Do you have any data which
will help us understand the performance benefit of these changes?

(2/2 has a typo in the subject and in the comment.  perferred->preferred)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ