windows: disable parallelism on Windows

This is an attempt to figure out why the Windows CI keeps crashing. It
should be removed before the next release, by which point we should know
whether this has helped or not.
Этот коммит содержится в:
Ayke van Laethem 2023-03-06 15:44:27 +01:00 коммит произвёл Ron Evans
родитель 8babc47638
коммит 192a55970f

Просмотреть файл

@ -1508,6 +1508,15 @@ func main() {
defer pprof.StopCPUProfile()
}
// Limit the number of threads to one.
// This is an attempted workaround for the crashes we're seeing in CI on
// Windows. If this change helps, it indicates there is a concurrency issue.
// If it doesn't, then there is something else going on. Either way, this
// should be removed once the test is done.
if runtime.GOOS == "windows" {
runtime.GOMAXPROCS(1)
}
switch command {
case "build":
pkgName := "."