3 ms·
As others mentioned, the POSIX alternative is poll() (and ppoll() as the alternative to pselect() ). If you want both portability and performance (as in, O(1)
by jabl 5y ago
As others mentioned, the POSIX alternative is poll() (and ppoll() as the alternative to pselect() ).
If you want both portability and performance (as in, O(1) instead of O(N) as poll() and select() ), there's no portable standard. In that case you're better of with a wrapper library like libuv or livev.