[lkml]   [2002]   [Sep]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: Heuristic readahead for filesystems
On Wed, 11 Sep 2002, Xuan Baldauf wrote:

> I wonder wether Linux implements a kind of heuristic
> readahead for filesystems:

> If an application did a stat() sequence on a
> file, it is likely that, after the next stat(), it will open
> and read the mentioned file. Thus, one could readahead the
> start of a file on stat() of that file.

> Example: See this diff strace:

Your observation is right, but I'm not sure how much it will
matter if we start reading the file at stat() time or at
read() time.

This is because one disk seek takes about 10 million CPU
cycles on modern systems and we'll have completed the stat(),
open() and started the read() before the disk arm has started
moving ;)


Bravely reimplemented by the knights who say "NIH".

Spamtraps of the month:

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:28    [W:0.364 / U:0.980 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site