[atratus-devel] [Lbw-users] Atratus project & v0.6 announcement
mike at atratus.org
Thu Mar 14 13:08:34 UTC 2013
On 02/13/2013 03:34 AM, David Given wrote:
> Have you managed to avoid any of the page size problems? I found this a
> right pain when loading ELF files, and had to fake it (badly).
I've had a look into this in the last month, and have something to report.
The problems stem from Windows allocating pages and sections in blocks
of 64k with 64k alignment.
Using the NT API, it seems possible to change page protections with
granularity of 4k. Underneath, chunks of 64k are allocated, but single
pages can be masked off (with PAGE_NOACCESS) from the client process.
Using this, and implementing some userspace "demand paging", I think it
will be possible to accurately emulate Linux's mmap in Windows.
Is there any problems you can see with this approach?
More information about the atratus-devel