logoalt Hacker News

Pesthuf • today at 7:51 AM • 1 reply • view on HN

Isn’t kqueue pretty much as fast as epoll?

There’s no io_uring, but in practice, almost all servers run epoll anyway, don’t they?


Replies

dijit • today at 11:39 AM

epoll isn’t very fast, kqueue is indeed much faster as a primitive.

MacOS’s implementation is an order of magnitude or more slower than (say) FreeBSD though, so its not a valid comparison that the syscall simply exists.

Another example of a syscall performing differently would be gettimeofday() in OpenBSD vs linux, its an extremely cheap operation in Linux but quite costly in OpenBSD despite being identical at the kernel boundary.