lkml.org 
[lkml]   [2009]   [Apr]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Linux 2.6.29


On Thu, 2 Apr 2009, Andrew Morton wrote:
>
> The thing which has always worried me about trying to do smart
> drop-behind is the cost of getting it wrong - and sometimes it _will_
> get it wrong.
>
> Someone out there will have an important application which linearly
> writes a 1G file and then reads it all back in again. They will get
> really upset when their runtime doubles.

Yes. The good news is that it would be a pretty easy tunable to have a
"how soon do we writeback and how soon would we drop". And I do suspect
that _dropping_ should default to off (exactly because of the kind of
situation you bring up).

As mentioned, at least in my experience the VM is pretty good at dropping
the right pages anyway. It's when they are dirty or locked that we end up
stuttering (or when we do fsync). And "start background writeout earlier"
improves that case regardless of drop-behind.
But at the same time it is also unquestionably true that the current
behavior tends to maximize throughput performance. Delaying the writes as
long as possible is almost always the right thing for througput.

In my experience, at least on desktops, latency is a lot more important
than throughput is. And I don't think anybody wants to start the writes
_immediately_.

Linus


\
 
 \ /
  Last update: 2009-04-03 01:09    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site