3 ms·
sbrk competes with mmap, not mprotect. And yes, I would expect mmap to be used in most modern systems. OS X, for instance, just emulates sbrk with a large stat
by koenigdavidmj 11y ago
sbrk competes with mmap, not mprotect.
And yes, I would expect mmap to be used in most modern systems. OS X, for instance, just emulates sbrk with a large static buffer, and it has no actual effect on the page tables.
- oso2k 11y ago4MB buffer to be exact [0]. [0] https://books.google.com/books?id=K8vUkpOXhN4C&pg=PA950&lpg=PA950&dq=osx+srbk+4mb&source=bl&ots=OLljV-UpVu&sig=n0NaVzZMEBKMk6FPZAsoOPF6JLo&hl=en&sa=X&ved=0CCgQ6AEwAWoVChMIxJOc7Yy-yAIVzlqICh0v-gov#v=onepage&q=osx%20srbk%204mb&f=false https://books.google.com/books?id=K8vUkpOXhN4C&pg=PA950&lpg=...
- duaneb 11y agoUpdated, sorry, they almost seem like the same API to me—I've never used one without the other. I have no idea whether that's actually the case.