3 ms·
> That does seem useful. But [...] That was mostly meant as an example of the more general case where using io-uring can reduce overhead of any kind of IO oper
by the8472 6y ago
> That does seem useful. But [...]
That was mostly meant as an example of the more general case where using io-uring can reduce overhead of any kind of IO operation, even when they're not the primary focus of your application.
The point is that yes, io-uring is great for event-based, asynchronous libraries. But even traditional synchronous code can make significant gains by switching to it. As the article hints with its package name: io-uring is the one ring to bind them all.
> This appears to be what the golang runtime will have to do.
The go standard library can tie io-uring into its goroutine scheduler. When doing IO it suspends the green thread, submits the work to IO uring and polls the completion queue of the ring when looking for tasks that need to be woken up.