aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/testdata
diff options
context:
space:
mode:
authorMichael Pratt <mpratt@google.com>2025-05-21 14:49:40 -0400
committerGopher Robot <gobot@golang.org>2025-05-21 13:00:42 -0700
commitd54703c94ae906a5e851ae95909b6eb2f0314e19 (patch)
tree3eca43d31558521b32e90bed7b927995b04c4198 /src/runtime/testdata
parentd82cb03debff0180aa705129e8a00e89c3fe8251 (diff)
downloadgo-d54703c94ae906a5e851ae95909b6eb2f0314e19.tar.xz
runtime: use DontUpdate testprog for DontUpdate test
This is a typo in CL 670497. The test is using the wrong testprog function. The testprog also needs to assert that GOMAXPROCS doesn't change, not that it is equal to NumCPU, for the GOMAXPROCS=4 case. For #73193. Cq-Include-Trybots: luci.golang.try:gotip-windows-amd64-longtest Change-Id: I6a6a636cab6936aa8519e3553b70ab6641ca8010 Reviewed-on: https://go-review.googlesource.com/c/go/+/675097 Auto-Submit: Michael Pratt <mpratt@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Michael Knyszek <mknyszek@google.com>
Diffstat (limited to 'src/runtime/testdata')
-rw-r--r--src/runtime/testdata/testprog/gomaxprocs_windows.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/testdata/testprog/gomaxprocs_windows.go b/src/runtime/testdata/testprog/gomaxprocs_windows.go
index bc7a4b1063..cae9dba8b3 100644
--- a/src/runtime/testdata/testprog/gomaxprocs_windows.go
+++ b/src/runtime/testdata/testprog/gomaxprocs_windows.go
@@ -56,8 +56,8 @@ func WindowsUpdateGOMAXPROCS() {
}
func WindowsDontUpdateGOMAXPROCS() {
- ncpu := runtime.NumCPU()
+ procs := runtime.GOMAXPROCS(0)
setAffinity2()
- mustNotChangeMaxProcs(ncpu)
+ mustNotChangeMaxProcs(procs)
println("OK")
}