简体   繁体   中英

What is the essential difference between event library (libevent/libuv/...) and async I/O (libaio, liburing)?

For high-performance I/O, some techniques are often used:

  • poll/select/epoll/kqueue: They are the same type of system calls that support I/O multiplexing.
  • libevent/libev/libuv: They are cross-platform. I think they wrap the above system calls and eventually implement event-driven.
  • libaio/libeio/liburing: They provide support for asynchronous IO.

It seems that all of them can achieve high performance, and libevent/libev/libuv is probabily to be better than poll/select/epoll/kqueue in terms of ease of use and cross-platform. But both libevent/libev/libuv and libaio/libeio/liburing seem to be excellent and seem to be interchangeable.

What is the essential difference between event library and async I/O? Which one is better to use in which situation?

Thanks.

Check my other answer: io_uring in multithreaded process

io_uring is the only one who can do real async io without a threadpool.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM