[Webkit-unassigned] [Bug 65766] [GTK] OSAllocator::reserveUncommitted should not commit physical memory

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Jul 22 12:55:48 PDT 2012


--- Comment #8 from Uli Schlachter <psychon at znc.in>  2012-07-22 12:55:53 PST ---
(In reply to comment #1)
> We need a mechanism to map VM space without reserving physical memory.  It sounds like MAP_NORESERVE should do exactly this, so my first question would be, why is this not working?  If the kernel is not obeying the MAP_NORESERVE flag, it seems there are two options:
> (1) Make the kernel obey MAP_NORESERVE.
> (2) Find an alternate interface that will allocate VM without reserving physical memory.

Mapping anonymous memory read-only doesn't make the (linux) kernel count it as committed. That should make it possible to allocate virtual address space without reserving physical memory, even when overcommit is disabled.

Actually making this memory usable (OSAllocator::commit(), I guess) would then require mprotect() to make the memory writable/executable.

Could this scheme work? If not, which part did I miss?

Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

More information about the webkit-unassigned mailing list