From: Honggyu Kim <honggyu.kim@sk.com>
To: Gregory Price <gourry@gourry.net>
Cc: kernel_team@skhynix.com, Joshua Hahn <joshua.hahnjy@gmail.com>,
ying.huang@linux.alibaba.com, rafael@kernel.org, lenb@kernel.org,
gregkh@linuxfoundation.org, akpm@linux-foundation.org,
rakie.kim@sk.com, dan.j.williams@intel.com,
Jonathan.Cameron@huawei.com, dave.jiang@intel.com,
horen.chuang@linux.dev, hannes@cmpxchg.org,
linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org,
linux-mm@kvack.org, kernel-team@meta.com, 42.hyeyoo@gmail.com,
Honggyu Kim <honggyu.km@gmail.com>
Subject: Re: [PATCH v4] Weighted Interleave Auto-tuning
Date: Wed, 5 Feb 2025 11:26:06 +0900 [thread overview]
Message-ID: <5b9a3776-8661-423a-853f-87fa8b9a7633@sk.com> (raw)
In-Reply-To: <Z6Di3oLQg64W0hAM@gourry-fedora-PF4VCD3F>
Hi Gregory,
On 2/4/2025 12:38 AM, Gregory Price wrote:
> On Mon, Feb 03, 2025 at 09:44:29PM +0900, Honggyu Kim wrote:
>> Hi Joshua,
>>
>>> A node offlining (or even onlining with no new bandwidth information)
>>> will just mean that the node inherits whatever value is stored in
>>> iw_table at that moment, whether that contains the default values
>>> created on init or the last values that it had taken.
>>
>> It looks the call sequence is as follows.
>>
>> cxl_region_perf_attrs_callback()
>> -> cxl_region_update_coordinates()
>> -> node_set_perf_attrs()
>> -> mempolicy_set_node_perf()
>> -> reduce_interleave_weights()
>>
>> I haven't searched all the paths of cxl_region_perf_attrs_callback() via
>> cxlr->memory_notifier.notifier_call callback pointer, but maybe this
>> function is not called when a node is offlined, then I get node
>> offlining doesn't trigger re-weight calculation.
>
> This function is called any time a memory block status changes.
>
> static int cxl_region_perf_attrs_callback(struct notifier_block *nb,
> unsigned long action, void *arg)
> {
> ...
> if (nid == NUMA_NO_NODE || action != MEM_ONLINE)
> return NOTIFY_DONE;
> ...
> }
Ah, that's clear now.
>
> But it doesn't do anything if it's not a call to online a memory block,
> so the cached performance data in mempolicy won't change when blocks
> are taken offline.
>
> So the time the scenario you are proposing can arrise is when the device
> does not provide performance information (missing CDAT).
>
>
> If a user sets manual mode - they're on the hook to manage everything.
>
> This is system-wide setting - not a per-task setting. We've yet to see
> any strong use-case for individual task weights. If there is a use case
> for a task not being subject to system-wide weight changes then it's a
> use case for task-local weights.
>
> ~Gregory
Thanks for the explanation. Then except for the nitpicks that I left,
I'm fine with this.
Thanks,
Honggyu
next prev parent reply other threads:[~2025-02-05 2:26 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-28 22:23 Joshua Hahn
2025-01-31 14:23 ` Honggyu Kim
2025-02-01 16:49 ` Gregory Price
2025-02-01 16:53 ` Gregory Price
2025-02-02 13:51 ` Honggyu Kim
2025-02-02 14:12 ` Joshua Hahn
2025-02-03 12:44 ` Honggyu Kim
2025-02-03 15:38 ` Gregory Price
2025-02-05 2:26 ` Honggyu Kim [this message]
2025-02-02 13:44 ` Honggyu Kim
2025-02-04 7:50 ` Harry (Hyeonggon) Yoo
2025-02-04 16:30 ` Gregory Price
2025-02-12 17:27 ` Gregory Price
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=5b9a3776-8661-423a-853f-87fa8b9a7633@sk.com \
--to=honggyu.kim@sk.com \
--cc=42.hyeyoo@gmail.com \
--cc=Jonathan.Cameron@huawei.com \
--cc=akpm@linux-foundation.org \
--cc=dan.j.williams@intel.com \
--cc=dave.jiang@intel.com \
--cc=gourry@gourry.net \
--cc=gregkh@linuxfoundation.org \
--cc=hannes@cmpxchg.org \
--cc=honggyu.km@gmail.com \
--cc=horen.chuang@linux.dev \
--cc=joshua.hahnjy@gmail.com \
--cc=kernel-team@meta.com \
--cc=kernel_team@skhynix.com \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=rafael@kernel.org \
--cc=rakie.kim@sk.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
all inboxes | Powered by JetHome®