From: Dave Hansen <haveblue@us.ibm.com>
To: Paul Jackson <pj@sgi.com>
Cc: Anton Blanchard <anton@samba.org>, Andrew Morton <akpm@osdl.org>,
Simon.Derr@bull.net,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
ak@suse.de, IWAMOTO Toshihiro <iwamoto@valinux.co.jp>
Subject: Re: [Patch 4/4] cpusets top mask just online, not all possible
Date: Sat, 11 Sep 2004 21:43:29 -0700 [thread overview]
Message-ID: <1094964209.16406.22.camel@localhost> (raw)
In-Reply-To: <20040911192156.1da7c636.pj@sgi.com>
On Sat, 2004-09-11 at 19:21, Paul Jackson wrote:
> Just as code in kernel/sched.c:move_task_off_dead_cpu()
> updates the affected tasks cpus_allowed to move off a dead
> CPU, calling cpuset_cpus_allowed() to get a new list of
> candidate CPUs to be set in task->cpus_allowed, similarly I
> expect that disabling a Memory Node should result in some
> "move_task_off_dead_memory()" routine, that called a cpuset
> routine to be called "cpuset_mems_allowed()", to get a new
> list of Memory Nodes, to be set in task->mems_allowed.
>
> Does this expectation fit for you? If so, let me know when
> you want the"cpuset_mems_allowed()" routine - or take a stab
> at it yourself if you find that easier.
That seems pretty reasonable to me. The fallback order that's
implemented in move_task_off_dead_cpu() seems very similar to what needs
to be done for memory. However, those operations might have to occur a
bit earlier in the process for memory.
Consider a case where a zone is shrinking, and memory is being moved out
of a section inside of it. We should try to allocate the memory to move
pages from the shrinking area in the same zone, the same node, then in
other ever-less-optimal NUMA nodes.
But, this has to occur in any removal case, even before the node is
completely gone. So, for now, I think that we probably need to go about
the normal removal process, and make sure to update mems_allowed if a
process's page is migrated to a place that wasn't in its mems_allowed.
Is it easy to tell if a given page was influenced by a cpusets
allocation? How would the memory removal code know which task[s] to go
and update?
> There are other ways to skin this cat - feel free to offer
> such up if that fits your work better.
My only other idea is just to leave it alone for now. We're still a
good bit of time away from removing NUMA nodes and I'll probably have a
much better idea about what we need when that occurs.
Somebody correct me if you disagree, but I don't see merging memory
removal as something that's going to happen in the next couple of
months. The work that I'm doing on it now is more so that I can
robustly test addition over, and over, and over again and get
_additiion_ in a mergable state.
I hate to have you or anyone else do a bunch of work for something that
isn't in-tree or planned to be in-tree for a while. We'll fix it when
we get there :)
-- Dave
next prev parent reply other threads:[~2004-09-12 4:44 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-09-11 8:28 [Patch 0/4] four small cpuset patches Paul Jackson
2004-09-11 8:28 ` [Patch 1/4] cpusets display allowed masks in proc status Paul Jackson
2004-09-11 8:28 ` [Patch 2/4] cpusets simplify cpus_allowed setting in attach Paul Jackson
2004-09-11 8:28 ` [Patch 3/4] cpusets remove useless validation check Paul Jackson
2004-09-11 8:28 ` [Patch 4/4] cpusets top mask just online, not all possible Paul Jackson
2004-09-11 14:10 ` Anton Blanchard
2004-09-11 17:07 ` Paul Jackson
2004-09-11 17:28 ` Dave Hansen
2004-09-12 2:21 ` Paul Jackson
2004-09-12 4:43 ` Dave Hansen [this message]
2004-09-12 5:35 ` Paul Jackson
2004-09-12 5:42 ` Paul Jackson
2004-09-11 17:39 ` Dave Hansen
2004-09-11 18:55 ` Andi Kleen
2004-09-12 2:29 ` Paul Jackson
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=1094964209.16406.22.camel@localhost \
--to=haveblue@us.ibm.com \
--cc=Simon.Derr@bull.net \
--cc=ak@suse.de \
--cc=akpm@osdl.org \
--cc=anton@samba.org \
--cc=iwamoto@valinux.co.jp \
--cc=linux-kernel@vger.kernel.org \
--cc=pj@sgi.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