Re: [PATCH net-next] epoll: add EPOLLEXCLUSIVE support

From: Eric Dumazet
Date: Tue Feb 14 2012 - 16:06:20 EST


Le mardi 14 fÃvrier 2012 Ã 21:48 +0100, Hagen Paul Pfeifer a Ãcrit :
> High performance server sometimes create one listening socket (e.g. port
> 80), create a epoll file descriptor and add the socket. Afterwards
> create SC_NPROCESSORS_ONLN threads and wait for events. This often
> result in a thundering herd problem because all CPUs are scheduled.
>
> This patch add an additional flag to epoll_ctl(2) called EPOLLEXCLUSIVE.
> If a descriptor is added with this flag only one CPU is scheduled in.
>
> Signed-off-by: Hagen Paul Pfeifer <hagen@xxxxxxxx>
> Reported-by: Li Yu <raise.sail@xxxxxxxxx>
> Cc: Davide Libenzi <davidel@xxxxxxxxxxxxxxx>
> Cc: Eric Dumazet <eric.dumazet@xxxxxxxxx>
> ---

Seems pretty good to me.

Do you have some performance numbers to share ?




--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/