Hey,
I noticed that there was an ioloop "module" (if we can call it that) for select and poll and decided to add one for kqueue (aka kevent) BSDs high performance descriptor multiplexing API. I haven't done any of the configure glue stuff but the code is complete and works well. kqueue is available on all recent versions of FreeBSD, NetBSD, OpenBSD and Darwin (and therefore MacOS X). I've tested both pop3 and imap with no problems.
To get it working: (bodge method)
- replace IOLOOP_POLL (or IOLOOP_SELECT) with IOLOOP_KEVENT
- find liblib_a_SOURCES add ioloop-kevent.c to it
- find liblib_a_OBJECTS add ioloop-kevent.$(OBJEXT) to it
make
vi src/lib/Makefile
tar zxvf dovecot-0.99.8.1.tar.gz cp ioloop-kevent.c dovecot-0.99.8.1/src/lib/ cd dovecot-0.99.8.1/ ./configure vi config.h
There is a paper on kqueue which includes a performance evaulation here:
http://people.freebsd.org/~jlemon/papers/kqueue.pdf
Thanks,
Dominic
<dom at cus.org.uk>