cosmopolitan/libc/sysv/consts/MAP_NOFORK.S
Justine Tunney f7780de24b
Make realloc() go 100x faster on Linux/NetBSD
Cosmopolitan now supports mremap(), which is only supported on Linux and
NetBSD. First, it allows memory mappings to be relocated without copying
them; this can dramatically speed up data structures like std::vector if
the array size grows larger than 256kb. The mremap() system call is also
10x faster than munmap() when shrinking large memory mappings.

There's now two functions, getpagesize() and getgransize() which help to
write portable code that uses mmap(MAP_FIXED). Alternative sysconf() may
be called with our new _SC_GRANSIZE. The madvise() system call now has a
better wrapper with improved documentation.
2024-07-07 12:40:30 -07:00

2 lines
95 B
ArmAsm

#include "libc/sysv/consts/syscon.internal.h"
.syscon mmap,MAP_NOFORK,0,0,0,0,0,0,0,0x10000000