Eric Dumazet 3b24d854cb tcp/dccp: do not touch listener sk_refcnt under synflood
When a SYNFLOOD targets a non SO_REUSEPORT listener, multiple
cpus contend on sk->sk_refcnt and sk->sk_wmem_alloc changes.

By letting listeners use SOCK_RCU_FREE infrastructure,
we can relax TCP_LISTEN lookup rules and avoid touching sk_refcnt

Note that we still use SLAB_DESTROY_BY_RCU rules for other sockets,
only listeners are impacted by this change.

Peak performance under SYNFLOOD is increased by ~33% :

On my test machine, I could process 3.2 Mpps instead of 2.4 Mpps

Most consuming functions are now skb_set_owner_w() and sock_wfree()
contending on sk->sk_wmem_alloc when cooking SYNACK and freeing them.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-04-04 22:11:20 -04:00
..
2016-03-10 20:54:09 -05:00
2016-03-17 21:05:01 -04:00
2015-11-30 14:47:33 -05:00
2016-04-04 22:11:19 -04:00
2015-11-23 14:56:15 -05:00
2016-02-14 14:36:04 -08:00
2016-03-09 16:36:15 -05:00
2015-10-23 03:05:19 -07:00
2016-02-21 22:00:28 -05:00
2016-03-21 22:56:38 -04:00