[Libevent-users] How do i make a multi-threaded libevent server?

Niels Provos provos at citi.umich.edu
Fri May 11 11:46:42 EDT 2007


On 4/13/07, Steven Grimm <sgrimm at facebook.com> wrote:
> As for how to do it, my approach is documented on the libevent home page
> (or rather, there's a link there to my explanation) so I won't repeat
> myself. But I will say it's working well for us -- our memcached
> instances are handling close to twice the request volume they used to be
> able to handle when they were single-threaded, and they still have
> plenty of capacity to spare.

Hi Steven,

I would really like to see measurements on that.   Do you have any
graphs that show the performance differences between single-threaded
and multi-threaded implementation?

As a general point, as  more and more CPUs are multi-core now or
provide hyper threading, you get better resource utilization by making
your applications multi-threaded.    Libevent allows you to run
multiple event loops, so that you can have at least one per core.

Niels.


More information about the Libevent-users mailing list