git: socket: Use modulo-N for SO_REUSEPORT socket locating

Sepherosa Ziehau sephe at crater.dragonflybsd.org
Sun Jul 21 22:47:39 PDT 2013


commit c275f18d832361be28b150d3f4fd518914bdeba6
Author: Sepherosa Ziehau <sephe at dragonflybsd.org>
Date:   Mon Jul 22 13:15:50 2013 +0800

    socket: Use modulo-N for SO_REUSEPORT socket locating
    
    This greatly reduces TCP listen socket completion queue pool token
    contention thus saves more cpu time.
    
    When the testing box (i7-2600, broadcom 5719) is doing 335Kconns/s,
    TCP listen socket completion queue token contention is reduced from
    20K/s to 500/s and the idle time on each hyperthread is increased by
    ~5%.

Summary of changes:
 sys/netinet/in_pcb.c | 11 +++++++++++
 1 file changed, 11 insertions(+)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/c275f18d832361be28b150d3f4fd518914bdeba6


-- 
DragonFly BSD source repository



More information about the Commits mailing list