udp/usrreq: Implement asynchronized pru_attach for UDP
commit2e3ddc46e56dc1b226dca69536b6b425bcb310f4
authorSepherosa Ziehau <sephe@dragonflybsd.org>
Thu, 22 Oct 2015 07:51:06 +0000 (22 15:51 +0800)
committerSepherosa Ziehau <sephe@dragonflybsd.org>
Thu, 22 Oct 2015 07:54:51 +0000 (22 15:54 +0800)
treeb755f4ec3e5f3b44d03919645793cba14467b34b
parent7a0f73c8674ea7aff5d32b7ac1b44b1ec189d621
udp/usrreq: Implement asynchronized pru_attach for UDP

The idea is same as c892825ffb53edaa4e5d7270b9254de80099dc53

The measured effect of this change on 2-ways E5-2600v2 with Intel 82599
(10Gbe) using tools/kq_connect_client -u, i.e. UDP socket/connect/send
/close before initiating a TCP connection:
- Connect rate increases by ~15Kconns/s; we are now doing 260Kconns/s.
- IPIs rate to the CPUs not running netisrs reduces (36Kipis/s ->
  23Kipis/s).
sys/netinet/udp_usrreq.c