4 ms·
So what's the difference with io_uring?
by escanda 3y ago
So what's the difference with io_uring?
- jabl 3y agoEpoll is a readyness notification API. You tell epoll which fd's you're interested in, then you run a poll operation which blocks until at least one of the fd's you're interested in is ready. Then you separately need to do the actual IO (which is essentially just a memcpy() between kernel and user space). In contrast io_uring is a completion notification API. You give it a buffer to read or write from/to, and it'll notify you when the IO has been completed. Io_uring is also more flexible, and can for example be used for disk IO which epoll can't.
- escanda 3y agoMakes sense. Also makes for much more efficient data polling since you get the buffer completed but not a random fd on which to perform yet another syscall.