HeadlinesBriefing favicon HeadlinesBriefing.com

io_uring vs libaio Performance: 2x Faster, Kernel Evolution, IOMMU Trap

Hacker News •
×

Linux developers have long known that io_uring outperforms the traditional libaio interface for asynchronous disk I/O, but concrete benchmarks across kernel versions have been surprisingly scarce. A team at YDB set out to measure how io_uring's performance evolved from Linux 5.4 through 6.18, using fio to test random 4K writes on NVMe hardware. Their findings reveal io_uring can be 2x faster than libaio, with the most performant io_uring configuration running 1.4x faster on newer kernels compared to older ones.

The testing uncovered an unexpected performance regression between kernels 5.4 and 5.15 affecting both libaio and non-SQPOLL io_uring modes. Initially alarming, this 30% IOPS drop turned out to be caused not by kernel regressions but by Intel IOMMU being enabled by default in newer releases. The team discovered that adding the intel_iommu=off kernel boot parameter restored performance to expected levels. This finding highlights how hardware configuration defaults can silently impact database performance.

Beyond the IOMMU discovery, the benchmarks demonstrate io_uring's consistent superiority across all tested iodepth ranges, delivering lower latency than libaio at every queue depth. The performance gap widens with newer kernels, making io_uring not just a drop-in replacement but a clear upgrade path for high-performance storage systems. For database developers and system administrators, these results provide concrete evidence that upgrading both kernel versions and I/O interfaces delivers measurable performance gains.