linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Linus Torvalds <torvalds@osdl.org>
To: Andi Kleen <ak@suse.de>
Cc: akpm@osdl.org, Christoph Lameter <clameter@engr.sgi.com>,
	linux-mm@kvack.org
Subject: Re: [PATCH for 2.6.16] Handle holes in node mask in node fallback list initialization
Date: Fri, 17 Feb 2006 10:38:26 -0800 (PST)	[thread overview]
Message-ID: <Pine.LNX.4.64.0602171030530.916@g5.osdl.org> (raw)
In-Reply-To: <200602171907.39236.ak@suse.de>


On Fri, 17 Feb 2006, Andi Kleen wrote:
> 
> That is why I added the !NODE_DATA(...) continue check
> It will just continue until it finds a usable node. 

The thing is, there is nothing to guarantee that it _ever_ finds a usable 
node. Let's say that we have nodes

	3 10

in the node map, then neither the old "i + n % 2" nor your new "i + n % 11" 
will ever actually hit either of the valid nodes at all when you traverse 
the thing. See? 

That's why I'm saying that the "(i + n) % any_random_number" just can't be 
right, and that you absolutely _have_ to use the numbers that 
"for_each_online_node()" gives you directly. Using anything else is always 
going to be buggy.

> > NOTE! I've not tested (and thus not debugged) it. I don't even have NUMA 
> > enabled, so I've not even compiled it. Somebody else please test it, and 
> > send it back to me with a sign-off and a proper explanation, and I'll sign 
> > off on it again and apply it.
> 
> I gave it a quick boot on the simulator with a missing node and it looks 
> good. Will test it a bit more and then resubmit it.

If it compiles (and I didn't just do something stupid like use the wrong 
variable or test the order the wrong way), I think my version is always 
safe. It doesn't play games with the node numbers, and it only really 
edits the "distance function" to have a dependency on the node 
relationship.

So if it works at all, I think it works every time. But I'm biased ;)

And I'll never argue against more testing.

			Linus

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

      reply	other threads:[~2006-02-17 18:38 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-02-17  1:23 Andi Kleen
2006-02-17  1:40 ` Christoph Lameter
2006-02-17  1:46   ` Andi Kleen
2006-02-17  2:12     ` KAMEZAWA Hiroyuki
2006-02-17  1:51 ` Christoph Lameter
2006-02-17  2:10   ` Andi Kleen
2006-02-17  2:46     ` Christoph Lameter
2006-02-17  6:10   ` Yasunori Goto
2006-02-17  9:58     ` Andi Kleen
2006-02-17 11:23       ` Bob Picco
2006-02-17 12:15         ` Andi Kleen
2006-02-17 14:34           ` Lee Schermerhorn
2006-02-17 16:05     ` Christoph Lameter
2006-02-17  3:33 ` Yasunori Goto
2006-02-17 16:52 ` Linus Torvalds
2006-02-17 18:07   ` Andi Kleen
2006-02-17 18:38     ` Linus Torvalds [this message]

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=Pine.LNX.4.64.0602171030530.916@g5.osdl.org \
    --to=torvalds@osdl.org \
    --cc=ak@suse.de \
    --cc=akpm@osdl.org \
    --cc=clameter@engr.sgi.com \
    --cc=linux-mm@kvack.org \
    /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