Subject: [linux-audio-dev] linux-kernel info: 2.4 Performance bug in read ahead
From: Roger Larsson (roger.larsson_AT_norran.net)
Date: Sat Jul 28 2001 - 05:52:29 EEST
Hi,
I have for some time wondered why reading two big (and identical) files
takes the double time of comparing them... today I found the cause :-)
Linux limits the read ahead to 1+31 pages (á 4096 bytes = 128 kB) with
modern HD this is read quickly (4.3 ms, with 30 MB/s) then the head has to
move...
You can hear the head moving when running diff on two big files...
I sent a patch to linux-kernel that corrects this (I changed the limit to 512
pages = 2MB).
But this can give a latency problem...
S streams reading full amount S*2MB will takes S*60 ms. But the kernel will
adopt a suitable read ahead for each sequential stream...
More about this later (including a patch) when the jury has returned...
/RogerL
-- Roger Larsson Skellefteå Sweden
This archive was generated by hypermail 2b28 : Sat Jul 28 2001 - 06:10:35 EEST