]> Cypherpunks repositories - gostls13.git/commit
runtime: relax the threshold for TestPingPongHog
authorCherry Mui <cherryyz@google.com>
Wed, 18 May 2022 19:15:33 +0000 (15:15 -0400)
committerCherry Mui <cherryyz@google.com>
Wed, 18 May 2022 19:52:53 +0000 (19:52 +0000)
commitc087121dafc1e0250d43b545e85d67e7e6762f74
tree76a6f0288f33af25185bbc1962d8e4e8ca75b390
parentfe4de36198794c447fbd9d7cc2d7199a506c76a5
runtime: relax the threshold for TestPingPongHog

The test checks that the scheduling of the goroutines are within
a small factor, to ensure the scheduler handing off the P
correctly. There have been flaky failures on the builder (probably
due to OS scheduling delays). Increase the threshold to make it
less flaky. The gap would be much bigger if the scheduler doesn't
work correctly.

For the long term maybe it is better to test it more directly
with the scheduler, e.g. with scheduler instrumentation.

May fix #52207.

Change-Id: I50278b70ab21b7f04761fdc8b38dd13304c67879
Reviewed-on: https://go-review.googlesource.com/c/go/+/407134
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Bryan Mills <bcmills@google.com>
Run-TryBot: Cherry Mui <cherryyz@google.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
src/runtime/proc_test.go