Lines Matching defs:mmap
45 #include <sys/mman.h> // for munmap, mmap, MADV_DONTNEED, etc
143 // The mmap top-down allocator will normally allocate below TASK_SIZE - gap,
144 // with a gap that depends on the max stack size. See x86/mm/mmap.c. We
154 // Give a random "hint" that is suitable for use with mmap(). This cannot make
155 // mmap fail, as the kernel will simply not follow the hint if it can't.
198 // Allocate |length| bytes of memory using mmap(). The memory will be
200 // Like mmap(), we will return MAP_FAILED on failure.
216 void* result = mmap(address_hint, length, PROT_READ|PROT_WRITE,
220 // If mmap() succeeded at a address_hint, our next mmap() will try to grow
229 // mmap failed or a collision prevented the kernel from honoring the hint,
274 "Whether mmap can be used to obtain memory.");
282 "Whether to randomize the address space via mmap().");
414 // Check if we should use mmap allocation.
419 // sbrk is used until the heap is exhausted (before mmap is used).
535 void *result = mmap(0, size + extra, PROT_WRITE|PROT_READ,
584 MmapSysAllocator *mmap = new (mmap_space) MmapSysAllocator();
587 // In 64-bit debug mode, place the mmap allocator first since it
598 // Our only random allocator is mmap.
599 sdef->SetChildAllocator(mmap, 0, mmap_name);
602 sdef->SetChildAllocator(mmap, 0, mmap_name);
606 sdef->SetChildAllocator(mmap, 1, mmap_name);