Slightly optimize read memory caching.

Since we are now using mmap for writing, there is no longer any need to
unmap read memory just because the file has been extended, since we are
requesting MAP_SHARED in both cases.

When mapping a window, extend the length to a page size multiple; thus,
need to ensure to read only the region that has been written so far.