Skip to content

Commit

Permalink
cmd/bench: run 10 iterations for each bent benchmark
Browse files Browse the repository at this point in the history
For golang/go#49207.

Change-Id: I83fa87a603cf26ed61d324975166388db1801487
Reviewed-on: https://go-review.googlesource.com/c/benchmarks/+/382097
Reviewed-by: David Chase <[email protected]>
Reviewed-by: Michael Pratt <[email protected]>
Trust: Michael Knyszek <[email protected]>
Run-TryBot: Michael Knyszek <[email protected]>
TryBot-Result: Gopher Robot <[email protected]>
  • Loading branch information
mknyszek committed Feb 9, 2022
1 parent 5430f30 commit d5e7b87
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions cmd/bench/bent.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,12 +107,16 @@ func bent(tcs []*toolchain) (err error) {
// Finally we can actually run the benchmarks.
// N.B. bent prints the "toolchain" tag to indicate which toolchain is being used.
// It's passed to bent via the TOML configuration.
cmd = exec.Command(bentPath, "-C", confFile, "-B", filepath.Join(dir, "benchmarks-50.toml"))
cmd = exec.Command(bentPath,
"-N", "10",
"-C", confFile,
"-B", filepath.Join(dir, "benchmarks-50.toml"),
)
cmd.Dir = dir
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
if err := cmd.Run(); err != nil {
return fmt.Errorf("error running bent -I: %w", err)
return fmt.Errorf("error running bent: %w", err)
}
return nil
}

0 comments on commit d5e7b87

Please sign in to comment.