From: Joshua Hahn <joshua.hahnjy@gmail.com>
To: YeeLi <seven.yi.lee@gmail.com>
Cc: akpm@linux-foundation.org, david@kernel.org,
dan.j.williams@intel.com, ying.huang@linux.alibaba.com,
linux-mm@kvack.org, joshua.hahnjy@gmail.com,
linux-kernel@vger.kernel.org, Jonathan.Cameron@huawei.com,
linux-cxl@vger.kernel.org, dave.jiang@intel.com,
gourry@gourry.next
Subject: Re: [PATCH] mm/mempolicy: add sysfs interface to override NUMA node bandwidth
Date: Thu, 12 Mar 2026 08:00:21 -0700 [thread overview]
Message-ID: <20260312150022.1373486-1-joshua.hahnjy@gmail.com> (raw)
In-Reply-To: <20260312091207.2016518-1-seven.yi.lee@gmail.com>
On Thu, 12 Mar 2026 17:12:07 +0800 YeeLi <seven.yi.lee@gmail.com> wrote:
Hello YeeLi,
I hope you are doing well! Thank you for the patch, I think it is an
interesting and helpful debugging tool.
> Automatic tuning for weighted interleaving [1] provides real benefits on
> systems with CXL support. However, platforms that lack HMAT or CDAT
> information cannot make use of this feature.
Thank you for the kind words : -) I'm also CCing Gregory Price, who
is the original author of the weighted interleave mempolicy.
> If the bandwidth reported by firmware or the device deviates from the
> actual measured bandwidth, administrators also lack a clear way to adjust
> the per-node weight values.
I just wanted to touch on this. Is this true? Weighted interleave already
exposes sysfs that lets the user set the weights they want. On one hand
I think it would be helpful for there to be a tool to see what the
effects of setting bandwidth information on a system could be, if it
had other side effects. I'm not sure if there is a strong case to do this
purely for weighted interleave auto-tuning, which already has a manual
weight override and pretty simple calculations : -)
> This patch introduces an optional Kconfig option,
> CONFIG_NUMA_BW_MANUAL_OVERRIDE (default n), which exposes node bandwidth
> R/W sysfs attributes under:
>
> /sys/kernel/mm/mempolicy/weighted_interleave/bw_nodeN
>
> The sysfs files are created and removed dynamically on node hotplug
> events, in sync with the existing weighted_interleave/nodeN attributes.
>
> Userspace can write a single bandwidth value (in MB/s) to override both
> read_bandwidth and write_bandwidth for the corresponding NUMA node. The
> value is then propagated to the internal node_bw_table via
> mempolicy_set_node_perf().
>
> This interface is intended for debugging and experimentation only.
Thank you for the helpful clarification. Just to be sure, are there
other intended things that the user can test other than what weights
weighted interleave would resolve to?
Thank you again for the patch, I hope you have a great day!
Joshua
> [1] Link:
> https://lkml.kernel.org/r/20250505182328.4148265-1-joshua.hahnjy@gmail.com
>
> Signed-off-by: yeeli <seven.yi.lee@gmail.com>
> ---
> mm/Kconfig | 20 +++++++
> mm/mempolicy.c | 148 +++++++++++++++++++++++++++++++++++++++++++++++++
> 2 files changed, 168 insertions(+)
next prev parent reply other threads:[~2026-03-12 15:00 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-12 9:12 YeeLi
2026-03-12 9:42 ` Huang, Ying
2026-03-12 10:26 ` Yee Li
2026-03-12 11:58 ` Jonathan Cameron
2026-03-13 3:05 ` Yee Li
2026-03-12 15:00 ` Joshua Hahn [this message]
2026-03-12 15:05 ` Joshua Hahn
2026-03-13 3:39 ` Yee Li
2026-03-12 16:12 ` Gregory Price
2026-03-13 3:51 ` Yee Li
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260312150022.1373486-1-joshua.hahnjy@gmail.com \
--to=joshua.hahnjy@gmail.com \
--cc=Jonathan.Cameron@huawei.com \
--cc=akpm@linux-foundation.org \
--cc=dan.j.williams@intel.com \
--cc=dave.jiang@intel.com \
--cc=david@kernel.org \
--cc=gourry@gourry.next \
--cc=linux-cxl@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=seven.yi.lee@gmail.com \
--cc=ying.huang@linux.alibaba.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox