go/runtime-bump-MaxGomaxprocs.patch
Jordi Massaguer 6c7505da54 Accepting request 479045 from home:cyphar:branches:devel:languages:go
- Add a patch to bump _MaxGomaxprocs so that things like Docker and k8s can run
  properly on NUMA machines. Don't bump this number too high. bsc#1028865
  + runtime-bump-MaxGomaxprocs.patch

OBS-URL: https://build.opensuse.org/request/show/479045
OBS-URL: https://build.opensuse.org/package/show/devel:languages:go/go?expand=0&rev=277
2017-03-31 09:53:21 +00:00

39 lines
1.2 KiB
Diff

From b75347d41a3771f8acab13a4dbd607254fdc5054 Mon Sep 17 00:00:00 2001
From: Aleksa Sarai <asarai@suse.de>
Date: Tue, 14 Mar 2017 00:14:38 +1100
Subject: [PATCH] runtime: bump _MaxGomaxprocs to (1 << 10)
This is required so that we can run k8s and Docker on machines with
quite large numbers of CPUs. (1 << 10) should be big enough /for now/.
SUSE: Don't upstream this.
Ref: bsc#1028865
Ref: https://github.com/golang/go/issues/13908
Signed-off-by: Aleksa Sarai <asarai@suse.de>
---
src/runtime/runtime2.go | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/src/runtime/runtime2.go b/src/runtime/runtime2.go
index 2e886742b528..eec28ba74f11 100644
--- a/src/runtime/runtime2.go
+++ b/src/runtime/runtime2.go
@@ -504,7 +504,12 @@ type p struct {
const (
// The max value of GOMAXPROCS.
// There are no fundamental restrictions on the value.
- _MaxGomaxprocs = 1 << 8
+ //
+ // SUSE: We bump this up quite a bit so you can run Docker and k8s on
+ // machines with massively more cores. Don't bump this value _too_
+ // much because it determines the size of some runtime arrays (which
+ // are used in scheduling, obviously).
+ _MaxGomaxprocs = 1 << 10
)
type schedt struct {
--
2.12.0