3 ms·
Modern allocators use mmap(2).
by myst 9y ago
Modern allocators use mmap(2).
- zaarn 9y agoThey do? Quite interesting. Tho it shouldn't really change the underlying mechanism; map only pages the process has touched.
- aduitsis 9y agoMay add, if you mmap(2) a memory segment (even a very large one, say 1Tb), nothing happens with regard to page mapping. It is not uncommon to see java tomcat processes allocating north of 80 Gb. But only a small percentage of these is actually used.
- loeg 9y agoWell, the page tables are initialized. Those aren't totally free, especially if a large mapping uses 4k pages.