mirror of
https://github.com/golang/go
synced 2024-11-23 07:40:04 -07:00
testing: improve the usage message of -benchtime
Specify that -benchtime can take the form Nx.
Change-Id: I1e711cdb2e19e3ff5eb2cea4e7c8843bc58696b1
GitHub-Last-Rev: 1cb13f7dba
GitHub-Pull-Request: golang/go#61756
Reviewed-on: https://go-review.googlesource.com/c/go/+/515801
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Run-TryBot: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
This commit is contained in:
parent
9869699c44
commit
64c1be144f
@ -25,7 +25,7 @@ import (
|
||||
func initBenchmarkFlags() {
|
||||
matchBenchmarks = flag.String("test.bench", "", "run only benchmarks matching `regexp`")
|
||||
benchmarkMemory = flag.Bool("test.benchmem", false, "print memory allocations for benchmarks")
|
||||
flag.Var(&benchTime, "test.benchtime", "run each benchmark for duration `d`")
|
||||
flag.Var(&benchTime, "test.benchtime", "run each benchmark for duration `d` or N times if `d` is of the form Nx")
|
||||
}
|
||||
|
||||
var (
|
||||
|
Loading…
Reference in New Issue
Block a user