]> Cypherpunks repositories - gostls13.git/commit
runtime: allow more CPUs on FreeBSD
authorAustin Clements <austin@google.com>
Tue, 26 Sep 2017 15:18:37 +0000 (11:18 -0400)
committerAustin Clements <austin@google.com>
Wed, 27 Sep 2017 16:29:18 +0000 (16:29 +0000)
commita714470cce03b28321a9dbcdbf34a99ab59deb75
tree611481867f8da325cb2745c44b7c97d59d6877b3
parente900e275e8667fde18973cdebe94861353162b87
runtime: allow more CPUs on FreeBSD

Currently the FreeBSD CPU affinity code assumes that the maximum
GOMAXPROCS is 256, but we just removed that limit.

This commit rewrites the FreeBSD CPU affinity code to raise the CPU
count limit to 65,536, like the Linux CPU affinity code, and to
degrade more gracefully if we do somehow go over that.

Change-Id: Ic4ca7f88bd8b9448aae4dbd43ef21a6c1b8fea63
Reviewed-on: https://go-review.googlesource.com/66291
Run-TryBot: Austin Clements <austin@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/runtime/os_freebsd.go