From: "Nish Aravamudan" <nish.aravamudan@gmail.com>
To: "stanojr@blackhole.websupport.sk" <stanojr@blackhole.websupport.sk>
Cc: linux-mm@kvack.org
Subject: Re: slow hugetlb from 2.6.15
Date: Tue, 27 Jun 2006 11:51:25 -0700 [thread overview]
Message-ID: <29495f1d0606271151w164202e8uce762b155a93ff1f@mail.gmail.com> (raw)
In-Reply-To: <20060627182325.GE6380@blackhole.websupport.sk>
On 6/27/06, stanojr@blackhole.websupport.sk
<stanojr@blackhole.websupport.sk> wrote:
> hello
>
> look at this benchmark
> http://www-unix.mcs.anl.gov/~kazutomo/hugepage/note.html
> i try benchmark it on latest 2.6.17.1 (x86 and x86_64) and it slow like 2.6.16 on
> that web
> (in comparing to standard 4kb page)
> its feature or bug ?
> i am just interested where can be hugepages used, but if they are slower than
> normal pages its pointless to use it :)
I believe your benchmark is measuring the time in such a way to make
current kernels look worse than older ones.
Basically, newer kernels (the ones that have the performance issue
you're seeing) use demand faulting of hugepages.
Thus, timing only the bench() call, as is done now, causes the newer
kernels to appear to take longer, as the pages must be zero'd, and the
page tables must be set up, as part of the bench() invocation (first
use).
In contrast, the older kernels would have done that up front, and thus
that time was not being accounted for in the bench() run.
There are a few ways to make sure this is the case:
1) Time the mmap, bench and unmap calls all together.
2) Add memset(addr, 1, LENGTH) and memset(addr, 0, LENGTH) calls
*before* bench(), to fault in the hugepages before running bench().
If the numbers return to normal after this, then the analysis above
should be accurate. If not, we do have a problem.
Thanks to Andy Whitcroft and Mel Gorman for insight into the potential problem.
Thanks,
Nish
--
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>
prev parent reply other threads:[~2006-06-27 18:51 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-06-27 18:23 stanojr
2006-06-27 18:47 ` Badari Pulavarty
2006-06-27 19:23 ` Chen, Kenneth W
2006-06-27 21:51 ` Dave Hansen
2006-06-27 22:00 ` Chen, Kenneth W
2006-06-27 18:51 ` Nish Aravamudan [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=29495f1d0606271151w164202e8uce762b155a93ff1f@mail.gmail.com \
--to=nish.aravamudan@gmail.com \
--cc=linux-mm@kvack.org \
--cc=stanojr@blackhole.websupport.sk \
/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