[Webkit-unassigned] [Bug 42756] JIT requires VM overcommit (particularly on x86-64), Linux does not by default support this without swap?

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Jan 12 14:25:09 PST 2011


https://bugs.webkit.org/show_bug.cgi?id=42756





--- Comment #30 from Oliver Hunt <oliver at apple.com>  2011-01-12 14:25:08 PST ---
(In reply to comment #29)
> > It should only be requesting 2gig, and it's expecting the OS to merely reserve address space -- it's not expecting physical memory to be committed.
> 
> 2GB is still a lot.
> 
> And if it counts on the OS not commiting it, then it counts on the memory not being used. Why ask for it then?
> 
> 
> Quoting the linux kernel documentation for memory overcommit,
> > When this flag is 1, the kernel pretends there is always enough
> > memory until it actually runs out.
> 
> I doubt that will ever become the default.
> It also leaves out a number of OSes that don't use overcommit (iirc, Solaris doesn't for instance).
> 
> Why isn't it possible to request 64MB instead? What's the technical reason for asking that much?

We allocate 2gig up front and do all allocations of executable memory from that region as we need to be able to guarantee that all executable allocations are within 2gig of each other - it would be a large amount of work (and a significant increase in code size) to support the arbitrary jumps to anywhere in the address space that would otherwise be necessary.

Surely Linux must have some mechanism for reserving an arbitrarily large amount of address space, and then commit that lazily?

-- 
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