Dave Cheney
9fb96991e6
net: fix data races on deadline vars
...
Fixes #4434 .
This proposal replaces the previous CL 6855110. Due to issue 599, 64-bit atomic operations should probably be avoided, so use a sync.Mutex instead.
Benchmark comparisons against 025b9d070a85 on linux/386:
CL 6855110:
benchmark old ns/op new ns/op delta
BenchmarkTCPOneShot 710024 727409 +2.45%
BenchmarkTCPOneShotTimeout 758178 768620 +1.38%
BenchmarkTCPPersistent 223464 228058 +2.06%
BenchmarkTCPPersistentTimeout 234494 242600 +3.46%
This proposal:
benchmark old ns/op new ns/op delta
BenchmarkTCPOneShot 710024 718492 +1.19%
BenchmarkTCPOneShotTimeout 758178 748783 -1.24%
BenchmarkTCPPersistent 223464 227628 +1.86%
BenchmarkTCPPersistentTimeout 234494 238321 +1.63%
R=rsc, dvyukov, mikioh.mikioh, alex.brainman, bradfitz
CC=golang-dev, remyoudompheng
https://golang.org/cl/6866050
2012-12-05 15:59:01 +11:00
Dave Cheney
5b425cc3ab
undo CL 6855110 / 869253ef7009
...
64bit atomics are broken on 32bit systems. This is issue 599.
linux/arm builders all broke with this change, I am concerned that the other 32bit builders are silently impacted.
««« original CL description
net: fix data races on deadline vars
Fixes #4434 .
R=mikioh.mikioh, bradfitz, dvyukov, alex.brainman
CC=golang-dev
https://golang.org/cl/6855110
»»»
R=rsc, mikioh.mikioh, dvyukov, minux.ma
CC=golang-dev
https://golang.org/cl/6852105
2012-11-30 20:02:30 +11:00
Dave Cheney
be0d84e335
net: fix data races on deadline vars
...
Fixes #4434 .
R=mikioh.mikioh, bradfitz, dvyukov, alex.brainman
CC=golang-dev
https://golang.org/cl/6855110
2012-11-30 18:26:51 +11:00
Sébastien Paolacci
7014bc64b1
net: spread fd over several pollservers.
...
Lighten contention without preventing further improvements on pollservers.
Connections are spread over Min(GOMAXPROCS, NumCPU, 8) pollserver instances.
Median of 10 runs, 4 cores @ 3.4GHz, amd/linux-3.2:
BenchmarkTCPOneShot 171917 ns/op 175194 ns/op 1.91%
BenchmarkTCPOneShot-2 101413 ns/op 109462 ns/op 7.94%
BenchmarkTCPOneShot-4 91796 ns/op 35712 ns/op -61.10%
BenchmarkTCPOneShot-6 90938 ns/op 30607 ns/op -66.34%
BenchmarkTCPOneShot-8 90374 ns/op 29150 ns/op -67.75%
BenchmarkTCPOneShot-16 101089 ns/op 111526 ns/op 10.32%
BenchmarkTCPOneShotTimeout 174986 ns/op 178606 ns/op 2.07%
BenchmarkTCPOneShotTimeout-2 101585 ns/op 110678 ns/op 8.95%
BenchmarkTCPOneShotTimeout-4 91547 ns/op 35931 ns/op -60.75%
BenchmarkTCPOneShotTimeout-6 91496 ns/op 31019 ns/op -66.10%
BenchmarkTCPOneShotTimeout-8 90670 ns/op 29531 ns/op -67.43%
BenchmarkTCPOneShotTimeout-16 101013 ns/op 106026 ns/op 4.96%
BenchmarkTCPPersistent 51731 ns/op 53324 ns/op 3.08%
BenchmarkTCPPersistent-2 32888 ns/op 30678 ns/op -6.72%
BenchmarkTCPPersistent-4 25751 ns/op 15595 ns/op -39.44%
BenchmarkTCPPersistent-6 26737 ns/op 9805 ns/op -63.33%
BenchmarkTCPPersistent-8 26850 ns/op 9730 ns/op -63.76%
BenchmarkTCPPersistent-16 104449 ns/op 102838 ns/op -1.54%
BenchmarkTCPPersistentTimeout 51806 ns/op 53281 ns/op 2.85%
BenchmarkTCPPersistentTimeout-2 32956 ns/op 30895 ns/op -6.25%
BenchmarkTCPPersistentTimeout-4 25994 ns/op 18111 ns/op -30.33%
BenchmarkTCPPersistentTimeout-6 26679 ns/op 9846 ns/op -63.09%
BenchmarkTCPPersistentTimeout-8 26810 ns/op 9727 ns/op -63.72%
BenchmarkTCPPersistentTimeout-16 101652 ns/op 104410 ns/op 2.71%
R=rsc, dvyukov, dave, mikioh.mikioh, bradfitz, remyoudompheng
CC=golang-dev
https://golang.org/cl/6496054
2012-09-26 15:32:59 -04:00
Russ Cox
f009fefd79
net: fix build (FreeBSD sendfile)
...
TBR=bradfitz
CC=golang-dev
https://golang.org/cl/6358043
2012-06-27 17:02:39 -04:00
L Campbell
a9a8d7b544
syscall, net: sendfile for FreeBSD
...
R=golang-dev, rsc, bradfitz, devon.odell
CC=golang-dev
https://golang.org/cl/6221054
2012-06-25 20:26:19 -04:00