Is mmap() reliable in 1.3.x?

Robert L Krawitz (rlk@tiac.net)
Wed, 27 Sep 1995 11:21:33 -0400


I'm working on an improved memory copy routine for the kernel on the
Pentium (it uses the FPU fildq/fistpq instructions to almost double
the throughput). I've observed, however, that when I use RCS
(actually CVS, but this uses RCS to do its work) compiled to use mmap
rather the normal read/write calls, that I occasionally get some data
corruption at the very beginning or end of a page in the file that RCS
uses.

I can't find anything otherwise wrong in my routine. It works fine in
user mode, and it otherwise works fine in the kernel, but there
appears to be some weird interaction with mmap. I haven't had time
yet to try to reproduce it under other circumstances. I'm wondering
if mmap is considered reliable or not, so I know where and whether to
keep looking.

Thanks!

-- 
Robert Krawitz <rlk@tiac.net>

Member of the League for Programming Freedom -- mail lpf@uunet.uu.net Tall Clubs International -- tci-request@think.com or 1-800-521-2512