testing: benchmark ignores time spent while timer is stopped when choosing N #23998
Labels
FrozenDueToAge
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
go version
)?go version go1.8.1 windows/amd64
Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (
go env
)?What did you do?
Benchmark a function that is quick but has a lot of delay while the timer is stopped.
The benchmark's N will grow very large due to the recorded time being short, but due to the delay during the time the timer is stopped, it will last a long amount of time
Here are the methods I tested with:
https://play.golang.org/p/uXHHPKoapbg
What did you expect to see?
Any of the following:
What did you see instead?
Benchmark got killed due to taking too long
The text was updated successfully, but these errors were encountered: