简体   繁体   English

zeromq 和 liburing (io_uring)

[英]zeromq and liburing (io_uring)

can anybody tell what is the main difference between zeromq and liburing in case of building tcp server in C?如果在 C 中构建 tcp 服务器,有人能说出 zeromq 和 liburing 之间的主要区别是什么吗? both can handle async requests and work with sockets. zeromq is older than liburing.两者都可以处理异步请求并使用 sockets。zeromq 比 liburing 旧。

io_uring can do real asynchronous IO, zeroMQ instead uses a thread pool. io_uring 可以做真正的异步 IO,zeroMQ 改为使用线程池。

The mitigations introduced for spectre, meltdown, retbleed and friends mean that context switching is much more expensive now, so thread pools approaches become bottle necked by CPU at high load.为 spectre、meltdown、retbleed 和 friends 引入的缓解措施意味着上下文切换现在要昂贵得多,因此线程池方法在高负载下成为 CPU 的瓶颈。

io_uring can sit at 20% cpu usage , while thread pools will starve due to 100% cpu usage. io_uring 可以坐在20% cpu 使用率,而线程池将由于 100% cpu 使用率而饿死。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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