Subject: Re: Partial fix for the NetBSD VM problem
To: Greg Hudson <ghudson@MIT.EDU>
From: Greg Hudson <ghudson@MIT.EDU>
List: tech-kern
Date: 03/02/1996 15:40:03
> * When you mmap() a file, you can wind up sharing pages with a
> previous map which is out of date with the actual file. It
> should not be necessary for every program to msync() after
> every mmap() call just to get a current view of the file.
It turns out that the part of my patch intended to fix this problem
(adding a vm_map_clean() to vm_mmap() for normal files) causes some
programs to hang when run twice at once (e.g. "echo foo | awk '{print
$1}' | awk '{print $1}'"). I'm not sure why. I'll check in the
msync() fix, but that won't fix the vi problem unless we add msync()
calls after the mmap() calls in vi.