From: Gregory Price <gourry@gourry.net>
To: "Huang, Ying" <ying.huang@linux.alibaba.com>
Cc: "Gregory Price" <gourry@gourry.net>,
"Joshua Hahn" <joshua.hahnjy@gmail.com>,
hyeonggon.yoo@sk.com, kernel_team@skhynix.com,
"rafael@kernel.org" <rafael@kernel.org>,
"lenb@kernel.org" <lenb@kernel.org>,
"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
"akpm@linux-foundation.org" <akpm@linux-foundation.org>,
"김홍규(KIM HONGGYU) System SW" <honggyu.kim@sk.com>,
"김락기(KIM RAKIE) System SW" <rakie.kim@sk.com>,
"dan.j.williams@intel.com" <dan.j.williams@intel.com>,
"Jonathan.Cameron@huawei.com" <Jonathan.Cameron@huawei.com>,
"dave.jiang@intel.com" <dave.jiang@intel.com>,
"horen.chuang@linux.dev" <horen.chuang@linux.dev>,
"hannes@cmpxchg.org" <hannes@cmpxchg.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-acpi@vger.kernel.org" <linux-acpi@vger.kernel.org>,
"linux-mm@kvack.org" <linux-mm@kvack.org>,
"kernel-team@meta.com" <kernel-team@meta.com>
Subject: Re: [External Mail] [RFC PATCH] mm/mempolicy: Weighted interleave auto-tuning
Date: Sun, 22 Dec 2024 11:54:54 -0500 [thread overview]
Message-ID: <Z2hEXttgNMjAo8-q@gourry-fedora-PF4VCD3F> (raw)
In-Reply-To: <87ldw8i0id.fsf@DESKTOP-5N7EMDA>
On Sun, Dec 22, 2024 at 04:29:30PM +0800, Huang, Ying wrote:
> Gregory Price <gourry@gourry.net> writes:
>
> > On Sat, Dec 21, 2024 at 01:57:58PM +0800, Huang, Ying wrote:
>
> Another choice is that if the user set a value, he/she set all values
> effectively. Even if he/she doesn't set the other values, he/she thinks
> that the other values are good, and more importantly, the ratio is good.
This is probably the actual way to go.
> If so,
>
> default_values [5,2,-] <- 1 node not set, expected to be hotplugged
> user_values [4,2,0] <- user has only set one value, not populated nodes have value 0
> effective [4,2,0]
>
> hotplug event
> default_values [2,1,1] - reweight has occurred
> user_values [4,2,0]
> effective [4,2,0]
>
> In this way, 0 becomes a valid value too.
>
> What do you think about this?
>
We decided when implementing weights that 0 was a special value that
reverts to the system default:
Writing an empty string or `0` will reset the weight to the
system default. The system default may be set by the kernel
or drivers at boot or during hotplug events.
I'm ok pulling the default weights in collectively once the first one is
written, but 0 is an invalid value which causes issues.
We went through that when we initially implemented the feature w/ task-local
weights and why the help function overrides it to 1 if it's ever seen.
We'll revert back to our initial implementation w/ default_iw_table and
iw_table - where iw_table contains user-defined weights. Writing a 0 to
iw_table[N] will allow get_il_weight() to retrieve default_iw_table[N]
as the docs imply it should.
~Gregory
next prev parent reply other threads:[~2024-12-22 16:55 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-10 21:54 Joshua Hahn
2024-12-13 6:19 ` [External Mail] " Hyeonggon Yoo
2024-12-13 16:28 ` Gregory Price
2024-12-13 19:57 ` Joshua Hahn
2024-12-16 7:53 ` Hyeonggon Yoo
2024-12-16 15:46 ` Joshua Hahn
2024-12-21 5:57 ` Huang, Ying
2024-12-21 14:58 ` Gregory Price
2024-12-22 8:29 ` Huang, Ying
2024-12-22 16:54 ` Gregory Price [this message]
2024-12-25 0:25 ` Huang, Ying
2024-12-25 9:30 ` Joshua Hahn
2024-12-26 1:35 ` Huang, Ying
2024-12-26 18:13 ` Gregory Price
2024-12-27 1:59 ` Huang, Ying
2024-12-27 15:35 ` Gregory Price
2024-12-30 6:48 ` Huang, Ying
2025-01-08 1:19 ` [External Mail] " Hyeonggon Yoo
2025-01-08 16:56 ` Joshua Hahn
2025-01-09 15:56 ` Gregory Price
2025-01-09 17:18 ` Joshua Hahn
2025-01-09 19:10 ` Joshua Hahn
2025-01-21 11:01 ` Huang, Ying
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=Z2hEXttgNMjAo8-q@gourry-fedora-PF4VCD3F \
--to=gourry@gourry.net \
--cc=Jonathan.Cameron@huawei.com \
--cc=akpm@linux-foundation.org \
--cc=dan.j.williams@intel.com \
--cc=dave.jiang@intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=hannes@cmpxchg.org \
--cc=honggyu.kim@sk.com \
--cc=horen.chuang@linux.dev \
--cc=hyeonggon.yoo@sk.com \
--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