From: Roman Dubtsov <dubtsov@gmail.com>
To: linux-kernel@vger.kernel.org
Subject: mmap() scalability in the presence of the MAP_POPULATE flag
Date: Wed, 02 Jan 2013 23:50:18 +0700 [thread overview]
Message-ID: <1357145418.5429.17.camel@mesosphere.localdomain> (raw)
Concurrent mmap() calls from the same process are serialized via downing
mm->mmap_sem for write. This means that operations like populating the
pages which do not alter vmas are also performed serially. Anecdotal
data from two machines I have access to is that populating pages by
touching them in a loop outside of mmap() improves performance of the
synthetic micro-benchmark by ~40% in the worst case. A crude patch that
modifies vm_mmap_pgoff() to call make_pages_present() outside of
do_mmap_pgoff() after upping the semaphore when MAP_POPULATE is present
brings identical performance improvement.
Is there an interest in fixing this or concurrent mmaps() from the same
process are too much of a corner case to worry about it?
Regards,
Roma
next reply other threads:[~2013-01-02 16:50 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-02 16:50 Roman Dubtsov [this message]
2013-01-03 0:09 ` Michel Lespinasse
2013-01-03 17:09 ` Roman Dubtsov
2013-01-04 11:57 ` Michel Lespinasse
2013-01-05 6:40 ` Roman Dubtsov
2013-01-05 7:43 ` Michel Lespinasse
2013-01-31 0:31 ` Michel Lespinasse
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=1357145418.5429.17.camel@mesosphere.localdomain \
--to=dubtsov@gmail.com \
--cc=linux-kernel@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
all inboxes | Powered by JetHome®