...and encourages extremely bad, incorrect, unsafe code (MAP_FIXED on address you don't already own) as a workaround.
-
-
A lock in mmap/mremap/munmap. best to solve in the kernel which serialises MM changes with a per mm RW lock e.g. down_write(&mm->mmap_sem);
-
That doesn't help. It's the caller that needs atomicity, not the implementation of mmap/mremap/munmap.
-
You could use such a lock in the implementation of mmap to work around kernels that don't implement requested-address, though.
-
Yes. I'm doing similar but instead replacing default address and my current hack is not thread safe. I don't have the kernels view of VMAs.
End of conversation
New conversation -
-
-
So I see stack_guard_gap is 1MiB. Wonder about non growable stacks e.g. no expand_stack and just regular anonymous maps for stacks.
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.