:ask for 8k, but the system will fetch the next 64k of data.  Problem is
:the system does nothing until you read the next 8k past the 64k
:alreqady read in, then it jumps up and grabs the next 64k.  You're
:still waiting on I/O every 8th read.  Ideally it would do an async
:       Dan Nelson

    No, this isn't true.  The system places a marker 8K or 16K before the
    last read block and initiates the next read-ahead before you exhaust the
    first one.

    For mapped data the system intentionally does not map the page table entry
    for a page or two before the end of the read ahead in order to force a
    page fault so it can initiate the next read ahead.

    For read data the system marks a buffer near the end of the read ahead
    so when read encounters it the system knows to queue then next read-ahead.

    Also, for that matter, remember that the hard drives themselves generally
    cache whole tracks and do their own read-ahead.  This is why dd'ing a 
    large file usually results in the maximum transfer rate the hard drive
    can do.

                                        Matthew Dillon 
                                        <[EMAIL PROTECTED]>
[EMAIL PROTECTED] mailing list
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to