MacBook Pro (13-inch, 2017)
Intel(R) Core(TM) i7-7567U CPU @ 3.50GHz
16 GB 2133 MHz LPDDR3
$ go test -bench=.
goos: darwin
goarch: amd64
Benchmark1ThreadNoCacheLineBouncing-4 100000000 15.2 ns/op
Benchmark1ThreadCacheLineBouncing-4 100000000 14.5 ns/op
Benchmark2ThreadsNoCacheLineBouncing-4 100000000 14.5 ns/op
Benchmark2ThreadsCacheLineBouncing-4 30000000 55.2 ns/op
Benchmark4ThreadsNoCacheLineBouncing-4 50000000 26.9 ns/op
Benchmark4ThreadsCacheLineBouncing-4 10000000 123 ns/op
Benchmark8ThreadsNoCacheLineBouncing-4 30000000 47.8 ns/op
Benchmark8ThreadsCacheLineBouncing-4 10000000 245 ns/op
PASS
ok scratchpad/golang/cache-bouncing 13.087s