]> Cypherpunks repositories - gostls13.git/commit
runtime: remove arbitrary timeouts in finalizer tests
authorBryan C. Mills <bcmills@google.com>
Thu, 8 Dec 2022 13:24:57 +0000 (08:24 -0500)
committerGopher Robot <gobot@golang.org>
Thu, 8 Dec 2022 14:19:25 +0000 (14:19 +0000)
commiteaf0e3d4650fd223dec84ee52025c7a82bcb24bd
tree9ef8e42ad02684316c4158fa2d848e9e46d2751d
parentc8313d4fa8ca04a1844edcb4a6e1f61cf13fd40e
runtime: remove arbitrary timeouts in finalizer tests

These short timeouts can overrun due to system scheduling delay
(or GC latency) on a slow or heavily-loaded host.

Moreover, if the test deadlocks we will probably want to know what the
GC goroutines were doing at the time. With an arbitrary timeout, we
never get that information; however, if we allow the test to time out
completely we will get a goroutine dump (and, if GOTRACEBACK is
configured in the environment, that may even include GC goroutines).

Fixes #57166.

Change-Id: I136501883373c3ce4e250dc8340c60876b375f44
Reviewed-on: https://go-review.googlesource.com/c/go/+/456118
Auto-Submit: Bryan Mills <bcmills@google.com>
Run-TryBot: Bryan Mills <bcmills@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Austin Clements <austin@google.com>
src/runtime/mfinal_test.go