Is libuv just a wrapper on libev on POSIX systems?

梦想与她 提交于 2019-12-22 08:36:36

问题


I am really confused between libev and libuv.

Is libuv just a wrapper on libev on POSIX systems?

If not where does it differ?


回答1:


No longer, since libuv-v0.9

Here is the libuv github issue which tracked the removal of libev from libuv.

The reasons for removal are, to quote from the above linked issue:

In case any project watchers are wondering, libev served us well but:

  1. It only supports level-triggered I/O. On Linux, we want to use edge-triggered mode - it cuts down the number of syscalls by a substantial margin.

  2. libev's inner loop does a lot of things we don't really need. Gutting the inner loop like we did in 649ad50 gave a 40% performance increase on some benchmarks.




回答2:


For completeness, as of today, we still don't use edge-triggered I/O on Linux.



来源:https://stackoverflow.com/questions/25174517/is-libuv-just-a-wrapper-on-libev-on-posix-systems

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!