Re: Random file I/O regressions in 2.6

Ram Pai
2004-05-03T22:09:08Z

On Mon, 2004-05-03 at 14:59, Andrew Morton wrote:

>
> > But how could read-ahead disabled end up in 16K request converted to
> > several sequential synchronous 4K requests ?
>
> Readahead got itself turned off because of pagecache hits and didn't turn
> itself on again.

Andrew,
In the slow read path, every contiguous access increases
ra->size by 1 and non-contiguous access decreases the
ra->size by 1. Now in the case of 16k random request,
we have 1 non-contiguous request and 3 contiguous request.
As a result the ra->size should have been incremented by
-1+1+1+1=2 . So at the end of 16 4K request we should have had
ra->size at 32. At this point onwards the readahead should get
turned on. Right?

I strongly feel the readahead got closed because of misses and
not because of hits. Moreover if we are closing readahead window
because of hits, then that implies we have pretty good caching
going on.Which implies i/o should rarely hit the disk and hence
performance should not degrade.

Agree?
RP

>
>