public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: Josh Aas <josha@sgi.com>
To: linux-ia64@vger.kernel.org
Subject: Re: free bootmem feedback patch
Date: Fri, 06 Aug 2004 18:27:41 +0000	[thread overview]
Message-ID: <4113CD9D.8000903@sgi.com> (raw)
In-Reply-To: <40F46962.4090604@sgi.com>

Luck, Tony wrote:
> Does the change:
> -			ClearPageReserved(page);
> +			(page)->flags &= ~(1UL << PG_reserved);
> 
> in the "else if (v)" clause actually make any difference?  I would
> expect not (unless you have bizarrely fragmented memory), so you
> could just leave the atomic operations there.

I imagine that change would make an improvement, no matter how small it 
is. Why not just do it? Especially after I define a macro.

> But it might be prettier to define a BootClearPageReserved() function
> in page-flags.h rather than expose the details of the implementation
> here in bootmem.c (in which case you could use this new function
> in the "else if (v)" clause too for symmetry).

I'll go ahead and create a macro for the non-atomic bit clear. Perhaps 
call it "ClearPageReservedNoAtomic" instead of "BootClearPageReserved"?

> Finally you have a magic "16" in the prefetchw() path.  Where did
> it come from, and is it the right number for non-ia64 machines?

My bad for not explaining that. In my limited testing of this particular 
number it seemed to be the sweet spot for prefetching. I think it is a 
good number for all architectures because 32 bit architectures won't 
need the speed boost as much as 64 bit architectures. They are not 
likely to have > 4GB memory,, in which case this function's time is 
probably less than 1 second anyway. So even though you have to wait 16 
iterations before you start getting the prefetched advantage, 32 bit 
architectures still get the improvement on half the iterations. It 
should be good for other 64 bit architectures because all architectures 
should be able to complete the prefetch by the 16th iteration, and all 
64 bit architectures will get the prefetched advantage in 48/64 
iterations (that might be OBO but whatever). I haven't used any 64 bit 
machines other than ia64 (or used prefetching before for that matter), 
so let me know if my logic is wrong. I do think that number could be 
tuned to a slightly better value, but 16 is nice and safe for now. And I 
only have ia64 boxes around.

> Here's a "Signed-off-by: Tony Luck <tony.luck@intel.com>" that
> you can cut-n-paste onto the patch when you repost to LKML.

Thanks.

>>Unfortunately, this still leaves a ~1 minute delay with no
>>indication of what is going on for 4TB machines, and ~2 minutes
>>for 8TB.
> 
> 
> Agreed that's long enough to cause worry, concern, even panic
> amongst nervous system administrators.  But I think that wli will
> hack this time down a lot more when he gets his patch together.
> So I'd like to wait and see what that looks like before I add the
> progress dots patch.

Sounds good.

-- 
Josh Aas
Silicon Graphics, Inc. (SGI)
Linux System Software
651-683-3068

  parent reply	other threads:[~2004-08-06 18:27 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-13 22:59 free bootmem feedback patch Joshua Aas
2004-07-13 23:14 ` Luck, Tony
2004-07-13 23:52 ` Joshua Aas
2004-07-14  8:44 ` Andi Kleen
2004-07-14  9:17 ` William Lee Irwin III
2004-07-14  9:19 ` William Lee Irwin III
2004-07-14 16:17 ` Joshua Aas
2004-07-14 18:34 ` Luck, Tony
2004-07-14 22:12 ` William Lee Irwin III
2004-07-15 19:11 ` Luck, Tony
2004-07-15 19:31 ` Matthew Wilcox
2004-07-15 20:21 ` David Mosberger
2004-07-15 23:16 ` William Lee Irwin III
2004-07-15 23:34 ` Matthew Wilcox
2004-07-15 23:53 ` Luck, Tony
2004-07-16  0:09 ` David Mosberger
2004-07-16  0:11 ` William Lee Irwin III
2004-07-16  0:18 ` Matthew Wilcox
2004-07-16  0:18 ` William Lee Irwin III
2004-08-03 17:53 ` Josh Aas
2004-08-03 23:53 ` William Lee Irwin III
2004-08-06 14:11 ` Josh Aas
2004-08-06 14:17 ` William Lee Irwin III
2004-08-06 17:58 ` Luck, Tony
2004-08-06 18:27 ` Josh Aas [this message]
2004-08-06 20:09 ` Luck, Tony
2004-08-06 20:51 ` William Lee Irwin III

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=4113CD9D.8000903@sgi.com \
    --to=josha@sgi.com \
    --cc=linux-ia64@vger.kernel.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