diff --git a/cpu/cpu_arm64.go b/cpu/cpu_arm64.go index bbaba18b..f3eb993b 100644 --- a/cpu/cpu_arm64.go +++ b/cpu/cpu_arm64.go @@ -6,7 +6,10 @@ package cpu import "runtime" -const cacheLineSize = 64 +// cacheLineSize is used to prevent false sharing of cache lines. +// We choose 128 because Apple Silicon, a.k.a. M1, has 128-byte cache line size. +// It doesn't cost much and is much more future-proof. +const cacheLineSize = 128 func initOptions() { options = []option{