From: Dave McCracken <dcm@mccr.org>
To: Keir Fraser <Keir.Fraser@eu.citrix.com>,
Jeremy Fitzhardinge <jeremy@goop.org>
Cc: Xen Developers List <xen-devel@lists.xensource.com>
Subject: RFC: Superpage/hugepage performance improvement
Date: Mon, 5 Apr 2010 12:52:29 -0500 [thread overview]
Message-ID: <201004051252.29210.dcm@mccr.org> (raw)
In our testing we found that the superpage/hugepage mapping code is seriously
bogged down by the need to maintain the reference count on each of the
underlying pages every time a hugepage is mapped. I came up with a fix where a
guest can call into the hypervisor to mark a set of pages as a superpage, thus
locking that set of pages to be read/write data pages until the corresponding
unmark is call is made. To make this work I added two mmuext ops, one to mark
a superpage and one to unmark it. This change makes a huge performance
difference in the hugepage mapping (on the order of 50 times faster).
On the Linux side, the hugepages are marked at the time they are put into the
hugepage pool, and unmarked when they are taken out of the pool. This
commonly happens very infrequently.
Does this mechanism sound reasonable to you all? If so, I'd like to make sure
the numbers we use for the new mmuext ops are reserved upstream so we won't
have to change them in the future.
I will port the actual patch forward to mainline shortly and send it off, but I
wanted to get an early indication of how you feel about the design.
Thanks,
Dave McCracken
Oracle Corp.
next reply other threads:[~2010-04-05 17:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-05 17:52 Dave McCracken [this message]
2010-04-06 9:29 ` RFC: Superpage/hugepage performance improvement Tim Deegan
2010-04-06 9:40 ` Keir Fraser
2010-04-06 14:12 ` Dave McCracken
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=201004051252.29210.dcm@mccr.org \
--to=dcm@mccr.org \
--cc=Keir.Fraser@eu.citrix.com \
--cc=jeremy@goop.org \
--cc=xen-devel@lists.xensource.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;
as well as URLs for NNTP newsgroup(s).