FairMQ
FairMQ copied to clipboard
Improve FairMQChannel polling to be O(1)
From FairRoot created by rbx : FairRootGroup/FairRoot#566
Current I/O multiplexing implementation in FairMQ for waiting on data on Channels behaves O(n). Polling unix sockets - hidden in the underlying zeromq/nanomsg libraries - is already O(1). All transports we currently support can expose the relevant operating system file descriptors which enables the usage of O(1) polling system calls - kqueue for MacOSX and epoll for Linux. Boost.Asio io services already nicely abstract such system APIs for us and according to Integrating Boost Asio with ZeroMQ integration is feasible.
A mockup shows that the edge-triggered interface exposed by ZeroMQ causes socket starvation in a simple implementation -> Investigate how AZMQ/czmq zloop solve this.