From: Paul Jackson <pj@sgi.com>
To: David Rientjes <rientjes@google.com>
Cc: Lee.Schermerhorn@hp.com, akpm@linux-foundation.org,
clameter@sgi.com, ak@suse.de, linux-kernel@vger.kernel.org,
mel@csn.ul.ie
Subject: Re: [patch 3/4] mempolicy: add MPOL_F_STATIC_NODES flag
Date: Wed, 13 Feb 2008 14:29:56 -0600 [thread overview]
Message-ID: <20080213142956.5ba52101.pj@sgi.com> (raw)
In-Reply-To: <alpine.DEB.1.00.0802131050240.9186@chino.kir.corp.google.com>
David wrote:
> You're specifically trying to avoid having the application know about its
> cpuset placement with regard to mems at the time it sets up its mempolicy,
> right? Otherwise it could already setup this relative nodemask by
> selecting node 2, from your example above, in its mems_allowed and it
> would always be remapped appropriately.
Yes, if an application considers nodes to be interchangeable, I'm
trying to avoid having that application -have- to know its current
cpuset placement, for two reasons:
For one thing, it's racey. It's cpuset placement could change,
unbeknownst to it, between the time it queried it, and the time
that it issued the mbind or set_mempolicy call.
For the other thing, it's not always possible. If the application
is currently in a cpuset that is smaller than it's preferred
configuration, it would not be possible to express its preferred
memory policies using just the smaller number of memory nodes
allowed by its current cpuset placement. How do you say "put
this on my third node" if you don't have a third node and you
can only speak of the nodes you currently have?
> So, for example, if the task is bound by mems 1-3, and it asks for
> MPOL_INTERLEAVE over 2-4, then initially the mempolicy is only effected
> over node 3 and if it's later expanded to mems 1-8, then the mempolicy is
> effected over nodes 3-5, right?
>
> And if the mems change to 3-8, the mempolicy is remapped to 5-7 even
> though 3-5 (which it already was interleaving over) is still accessible?
Yes and yes, for this cpuset relative numbering mode.
> Does MPOL_INTERLEAVE | MPOL_F_STATIC_NODES | MPOL_F_PAULS_NEW_FLAG make
> any logical sense? If it does, I think we're going to be writing some
> very complex remap code in our future.
No -- MPOL_F_STATIC_NODES and MPOL_F_RELATIVE_NODES (which is what I'll
likely call my new flag) are mutually exclusive.
The allowed modes and flags would be:
Choose exactly one of:
MPOL_DEFAULT, MPOL_PREFERRED, MPOL_BIND, MPOL_INTERLEAVE
Plus zero or one of:
MPOL_F_STATIC_NODES, MPOL_F_RELATIVE_NODES
where, if you choose neither of tne MPOL_F_*_NODES flags,
then you get the classic, compatible nodemask handling.
> Well, I didn't cave on anything
;) Your simple "ok" was ambiguous enough that we were able to
read into it whatever we wanted to.
But I've made my case on that issue (involving the separate or
packed policy flag field). So I probably won't say more, and
I expect to live with whatever you choose, after any further
input from Lee or others.
--
I won't rest till it's the best ...
Programmer, Linux Scalability
Paul Jackson <pj@sgi.com> 1.940.382.4214
next prev parent reply other threads:[~2008-02-13 20:30 UTC|newest]
Thread overview: 78+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-11 15:30 [patch 1/4] mempolicy: convert MPOL constants to enum David Rientjes
2008-02-11 15:30 ` [patch 2/4] mempolicy: support optional mode flags David Rientjes
2008-02-11 15:30 ` [patch 3/4] mempolicy: add MPOL_F_STATIC_NODES flag David Rientjes
2008-02-11 15:30 ` [patch 4/4] mempolicy: update NUMA memory policy documentation David Rientjes
2008-02-11 16:10 ` Randy Dunlap
2008-02-11 20:06 ` [patch 4/4 v2] " David Rientjes
2008-02-11 20:14 ` Randy Dunlap
2008-02-11 18:25 ` [patch 3/4] mempolicy: add MPOL_F_STATIC_NODES flag KOSAKI Motohiro
2008-02-11 19:56 ` David Rientjes
2008-02-13 0:25 ` Lee Schermerhorn
2008-02-13 0:57 ` David Rientjes
2008-02-11 19:34 ` Christoph Lameter
2008-02-13 0:22 ` Lee Schermerhorn
2008-02-13 3:52 ` Paul Jackson
2008-02-13 4:03 ` David Rientjes
2008-02-13 4:13 ` Paul Jackson
2008-02-13 4:23 ` David Rientjes
2008-02-13 8:03 ` Paul Jackson
2008-02-13 9:36 ` David Rientjes
2008-02-13 16:01 ` Lee Schermerhorn
2008-02-13 18:48 ` David Rientjes
2008-02-13 18:58 ` Paul Jackson
2008-02-13 19:05 ` Lee Schermerhorn
2008-02-13 19:17 ` David Rientjes
2008-02-13 17:04 ` Paul Jackson
2008-02-13 19:02 ` David Rientjes
2008-02-13 20:29 ` Paul Jackson [this message]
2008-02-13 21:35 ` David Rientjes
2008-02-14 11:12 ` Paul Jackson
2008-02-14 12:27 ` Paul Jackson
2008-02-14 10:26 ` Paul Jackson
2008-02-14 19:45 ` David Rientjes
2008-02-15 10:19 ` Paul Jackson
2008-02-15 20:14 ` David Rientjes
2008-02-13 4:18 ` David Rientjes
2008-02-13 5:06 ` David Rientjes
2008-02-13 15:15 ` Lee Schermerhorn
2008-02-13 16:14 ` Lee Schermerhorn
2008-02-13 19:12 ` David Rientjes
2008-02-14 10:09 ` Paul Jackson
2008-02-14 19:40 ` David Rientjes
2008-02-15 1:44 ` David Rientjes
2008-02-15 10:00 ` Paul Jackson
2008-02-14 21:38 ` David Rientjes
2008-02-15 9:27 ` Paul Jackson
2008-02-15 20:23 ` David Rientjes
2008-02-15 20:32 ` David Rientjes
2008-02-15 23:45 ` Paul Jackson
2008-02-15 23:55 ` David Rientjes
2008-02-16 0:11 ` Paul Jackson
2008-02-11 16:36 ` [patch 2/4] mempolicy: support optional mode flags Lee Schermerhorn
2008-02-11 19:34 ` David Rientjes
2008-02-12 15:31 ` Lee Schermerhorn
2008-02-12 19:14 ` David Rientjes
2008-02-11 20:55 ` Paul Jackson
2008-02-11 21:52 ` David Rientjes
2008-02-11 21:57 ` Paul Jackson
2008-02-13 0:14 ` Lee Schermerhorn
2008-02-13 0:25 ` David Rientjes
2008-02-11 18:45 ` [patch 1/4] mempolicy: convert MPOL constants to enum Andi Kleen
2008-02-11 19:25 ` David Rientjes
2008-02-11 19:32 ` Christoph Lameter
2008-02-11 19:40 ` David Rientjes
2008-02-11 19:48 ` Christoph Lameter
2008-02-11 20:02 ` David Rientjes
2008-02-11 20:45 ` Christoph Lameter
2008-02-13 0:10 ` Lee Schermerhorn
2008-02-13 0:31 ` Paul Jackson
2008-02-13 0:53 ` David Rientjes
2008-02-13 1:04 ` Christoph Lameter
2008-02-13 1:28 ` Paul Jackson
2008-02-13 1:32 ` Paul Jackson
2008-02-13 2:00 ` David Rientjes
2008-02-13 2:22 ` Paul Jackson
2008-02-13 2:42 ` David Rientjes
2008-02-13 2:59 ` Paul Jackson
2008-02-13 3:17 ` David Rientjes
2008-02-13 3:22 ` 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=20080213142956.5ba52101.pj@sgi.com \
--to=pj@sgi.com \
--cc=Lee.Schermerhorn@hp.com \
--cc=ak@suse.de \
--cc=akpm@linux-foundation.org \
--cc=clameter@sgi.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mel@csn.ul.ie \
--cc=rientjes@google.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
Powered by JetHome