Epoll vs. io_uring in Linux
sibexi.co
Epoll vs. io_uring in Linux
1–10 of 79 posts
Re: Epoll vs. io_uring in Linux
#2Re: Epoll vs. io_uring in Linux
#3Re: Epoll vs. io_uring in Linux
#4Boost asio if you love C++ and asynchronous networking.
Re: Epoll vs. io_uring in Linux
#5Boost asio if you love C++ and asynchronous networking.
I switched out asio's epoll backend for its io_uring in a database server and CPU utilization shot up. Probably depends on usage and the specifics of how it's integrated into the event code.
Re: Epoll vs. io_uring in Linux
#6Re: Epoll vs. io_uring in Linux
#7Yes, io_uring is significantly faster than epoll (I think I had like 20% faster req/s with io_uring.) The catch is that its kernel opt-in and disabled just about everywhere for security reasons. I think that it has direct memory sharing between the kernel and user-land which is kind of yikes. There's been multiple exploits that hit io_uring in recent times. It's because of this that even engineering projects that try…
Rdma, dpdk, io_uring it’s really kind of up to the user to do the memory isolation
In io_urings case tho, you can’t do much because the rings are in the kernel.
I’m hopeful though that with Llm things will get better.
But it’s just hard problem to solve . Very difficult to do in the kernel itself, and folks don’t really even understand tuning for it.
Re: Epoll vs. io_uring in Linux
#8Earlier quoted context omitted.
I switched out asio's epoll backend for its io_uring in a database server and CPU utilization shot up. Probably depends on usage and the specifics of how it's integrated into the event code.
That’s paradoxically what you can expect on a busy server - your CPU can spend time doing work that would have been previously IO wait time. Of course, it could be a bug in the implementation where you’re spinning doing no work erroneously, but depends on the details.
Re: Epoll vs. io_uring in Linux
#9Re: Epoll vs. io_uring in Linux
#10Yes, io_uring is significantly faster than epoll (I think I had like 20% faster req/s with io_uring.) The catch is that its kernel opt-in and disabled just about everywhere for security reasons. I think that it has direct memory sharing between the kernel and user-land which is kind of yikes. There's been multiple exploits that hit io_uring in recent times. It's because of this that even engineering projects that try…