> While these entry points do not actually modify the file itself,
I disagree.
You don't worry about the timestamp being updated _during_ a large
write() call, even though the file is constantly being modified.
You think of write() as something instantaneous, while you think of
writing to a shared mapping, then doing msync() as something taking a
long time. In actual fact both of these are basically equivalent
operations, the differences being, that you can easily modify
non-contiguous parts of a file with mmap, while you can't do that with
write. The disadvantage from mmap comes from the cost of setting up
the page tables and handling the faults.
Think of it this way:
shared mmap write + msync(MS_ASYNC) == write()
msync(MS_ASYNC) + fsync() == msync(MS_SYNC)
I think this would just be a waste of CPU.
Miklos
-