3 ms·
mmap + C++ coroutines can be combined.
by germandiago 5y ago
mmap + C++ coroutines can be combined.
- pengaru 5y agoAnd? So you're going to take a syscall (mincore()?) hit before every file-backed mapping access to test if it'd incur a page fault, and try switch to another coroutine if it would? Syscalls aren't free, especially today, and mmap() is already bringing significant overhead to the party. If you've brought coroutines into the picture, you might as well schedule them using async IO completions and kick mmap() to the curb.
- jandrewrogers 5y agoWhat problem does this solve? Use of mmap() tends to imply blocking calls.