From: Andrew Morton <akpm@linux-foundation.org>
To: KOSAKI Motohiro <kosaki.motohiro@gmail.com>
Cc: Rik van Riel <riel@redhat.com>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Mel Gorman <mel@csn.ul.ie>, Johannes Weiner <hannes@cmpxchg.org>
Subject: Re: [PATCH -mm] make swapin readahead skip over holes
Date: Wed, 11 Jan 2012 15:15:45 -0800 [thread overview]
Message-ID: <20120111151545.4636bc49.akpm@linux-foundation.org> (raw)
In-Reply-To: <CAHGf_=qtpA5VTw5W0zaAhB2WCX1+-k59szTnDLnqDJeg+q9Jsw@mail.gmail.com>
On Wed, 11 Jan 2012 02:14:32 -0500
KOSAKI Motohiro <kosaki.motohiro@gmail.com> wrote:
> > Another factor is that swapping on modern systems is often a
> > temporary thing. During a load spike, things get swapped out
> > and run slowly. After the load spike is over, or some memory
> > hog process got killed, we want the system to recover to normal
> > performance as soon as possible. __This often involves swapping
> > everything back into memory.
>
> Hmmm.... OK, I have to agree this.
> But if so, to skip hole is not best way. I think we should always makes
> one big IO, even if the swap cluster have some holes. one big IO is
> usually faster than multiple small IOs. Isn't it?
Not necessarily. If we have two requests in the disk for blocks 0-3
and 8-11, one would hope that the disk is smart enough to read both
blocks within a single rotation.
If the kernel were to recognise this situation and request the entire
12 blocks then we'd see lower command overhead but higher transfer
costs.
Still, Rik's testing shows that either approach would be superior to
what we have at present, which is to not read blocks 8-11 at all!
It sounds like Rik will be doing a v2 with some minor updates?
--
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/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2012-01-11 23:15 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-09 23:10 [PATCH -mm] make swapin readahead skip over holes Rik van Riel
2012-01-09 23:49 ` KOSAKI Motohiro
2012-01-10 3:09 ` Rik van Riel
2012-01-11 7:14 ` KOSAKI Motohiro
2012-01-11 8:01 ` KOSAKI Motohiro
2012-01-11 8:05 ` KOSAKI Motohiro
2012-01-11 14:11 ` John Stoffel
2012-01-11 19:17 ` Christoph Lameter
2012-01-11 21:03 ` John Stoffel
2012-01-11 22:25 ` KOSAKI Motohiro
2012-01-11 23:15 ` Andrew Morton [this message]
2012-01-11 16:51 ` Mel Gorman
2012-01-11 19:23 ` Rik van Riel
2012-01-12 14:33 ` Mel Gorman
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=20120111151545.4636bc49.akpm@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=hannes@cmpxchg.org \
--cc=kosaki.motohiro@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mel@csn.ul.ie \
--cc=riel@redhat.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).