[zeromq-dev] ZMQ_POLL flag obsoleted
sustrik at 250bpm.com
Thu Apr 29 21:26:15 CEST 2010
There have been a change made to 0MQ today that trades some latency (2-3
us on Linux) for several advantages:
1. Unlimited number of threads (more than 64 which used to be the limit)
threads can communicate via 0MQ.
2. No need to set ZMQ_POLL flag to be able to use zmq_poll. The flag
still exists to ensure backward compatibility, but has no effect and
will be removed in the next version.
3. The change opens a way for specifying timeouts on zmq_send/zmq_recv
4. Significant codebase simplification.
1. Lock-free polling was removed (ypollset_t). It's a pitty, because it
was a clever algorithm and AFAIK it was never described in the
literature. Describing it would make a serious research paper. If
there's anyone interested, feel free to write such a paper, so that the
algorithm is not lost to humankind :)
2. atomic_bitset is removed. The only place it was used was lock-free
3. simple_semaphore was removed. It was more efficient than system
semaphore, but, on the other hand, it relied on undocumented properties
of mutexes so maybe it's better that it's gone.
More information about the zeromq-dev