[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Multiplexing alternatives to poll()...
Bruce Montrose wrote:
>
> Read this article comparing the various multiplexing techniques...
> http://www.kegel.com/dkftpbench/Poller_bench.html
>
> It would seem that either /dev/poll or kqueue could drastically improve our
> multiplexing in the onion router.
A better starting point might be http://www.kegel.com/c10k.html
I've co-authored a couple of /dev/epoll based servers at work. I'm not
sure how many connections the onion router needs to handle, or how busy
they'll be, but I think it's unlikely that any of these fast event
notification APIs will be required.
If I'm right, that's good news, because these mechanisms are all very
platform-specific, and a number of the better ones have yet to make it
into major OS releases. If you can get by without using any of these
APIs, that's a win.
If you do decide to use an advanced event notification mechanism, I can
recommend kqueue() as the most mature API, and /dev/epoll as a simple
and effective entry for Linux.
--
Steven Hazel
sah@thalassocracy.org