I am reading Redis recently. Redis implements a simple event-driven library based on I/O multiplexing. Redis says it would choose the best multiplexing supported by the system, and gives the following code:
/* Include the best multiplexing layer supported by this system.
* The following should be ordered by performances, descending. */
#ifdef HAVE_EVPORT
#include "ae_evport.c"
#else
#ifdef HAVE_EPOLL
#include "ae_epoll.c"
#else
#ifdef HAVE_KQUEUE
#include "ae_kqueue.c"
#else
#include "ae_select.c"
#endif
#endif
#endif
I wanna know whether they have fundamental performance differences? If so, why?
Best regards