Re: A fix for Re: Severe I/O performance regression 2.6.6 to 2.6.7or 2.6.8-rc3

From: Andrew Morton
Date: Sat Aug 07 2004 - 00:01:16 EST


Berkley Shands <berkley@xxxxxxxxxxxx> wrote:
>
> Taking the 2.6.6-bk6/mm/readahead.c (a one line change from vanilla 2.6.6/mm/readahead.c)
> and inserting it into 2.6.7 and 2.6.8-rc3 restores the thread read ahead functionality
> and througput seen in the 2.6.6 kernel. This does however reduce the single stream read
> performance from 426MB/Sec (under 2.6.8-rc3) to 386MB/Sec (same as 2.6.6).
> The major functionality change was to try to detect "random" read performance,
> if randomness is detected, then NEVER read ahead. In this case, two threads
> using two different file descriptors to the same file read alternating strides
> of the file. Since each thread did not do SEQUENTIAL reads, both were treated as random
> accesses.

Let me attempt to clarify here. You have two fd's open against the same
file and you are reading in the following manner:

fd1: 0-11k 33-44k 55-66k
fd2: 11-22k 44-55k

yes?

If correct, I think you're expecting a bit too much of the readahead
system. If you have a real application which is using such access patterns
perhaps it should be taught to use POSIX_FADV_WILLNEED.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/