cmd/dist: run racebench tests only in longtest mode

The racebench tests represent a significant portion of the race
builders' runtimes, but these tests aren't providing a lot of value.
Disable them and run them only on -longtest-race builders.

For #32032.

Change-Id: Ic4383c3f3b51d123ae9f5c377bc0e2ec02f2ddd7
Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-race,gotip-linux-amd64-longtest-race
Reviewed-on: https://go-review.googlesource.com/c/go/+/700455
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
TryBot-Bypass: Michael Knyszek <mknyszek@google.com>
This commit is contained in:
Michael Anthony Knyszek 2025-09-02 18:35:21 +00:00 committed by Michael Knyszek
parent 355370ac52
commit b09068041a

View file

@ -677,7 +677,7 @@ func (t *tester) registerTests() {
} }
t.registerStdTest(pkg) t.registerStdTest(pkg)
} }
if t.race { if t.race && !t.short {
for _, pkg := range pkgs { for _, pkg := range pkgs {
if t.packageHasBenchmarks(pkg) { if t.packageHasBenchmarks(pkg) {
t.registerRaceBenchTest(pkg) t.registerRaceBenchTest(pkg)