2 ms·
I don't remember if the ABI kind of made it so that they can't increase that constant. Like if the next meaningful return code started at 65... As I recall they
by asveikau 6y ago
I don't remember if the ABI kind of made it so that they can't increase that constant. Like if the next meaningful return code started at 65... As I recall they had this WAIT_OBJECT_0 + offset scheme, maybe offset 65 was something else meaningful? It's been a while.
But if they had meaningfully increased that, then they would run into the same scaling problems as poll(2) - since the return code gives you an index, you wouldn't have to loop through the handle set in user mode like pollfd requires, but every syscall would need an O(n) scan of the HANDLE[] array on the kernel side. You need something like iocp/epoll/kqueue where kernel mode has a list of interesting handles, that doesn't need to be scanned and copied at every syscall.