Re: mmap() versus read()

MOLNAR Ingo (mingo@chiara.csoma.elte.hu)
Sun, 8 Mar 1998 23:06:23 +0100 (CET)


On Sun, 8 Mar 1998, Hans Reiser wrote:

> I disagree. If you page fault more than once, so as to establish a
> pattern of sequentiality, you are already losing compared to madvise().

not if the (autodetected) access pattern is persistant, eg. you save the
pattern into the filesystem itself ... this is IMO better than madvise(),
since madvise() carries only very few information, and madvise() has no
knowledge about the underlying block device, eg. you might be using a
solid state disk with no seek cost (or a ramdisk).

thus madvise() might even turn out to be an overhead, on a sufficiently
smart kernel and/or on sufficiently smart hardware.

-- mingo

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu