The function argument passed to hash function escaped to heap when
optimization is disabled, causing the builder failed.
To fix this, skip the test on noopt builder.
Updates #71943
Fixes #71965
Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-noopt
Change-Id: I3a9ece09bfa10bf5eb102a7da3ade65634565cb4
Reviewed-on: https://go-review.googlesource.com/c/go/+/652735
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Auto-Submit: Cuong Manh Le <cuong.manhle.vn@gmail.com>
import (
"crypto/sha256"
+ "internal/testenv"
"runtime"
"testing"
)
}
func TestIssue71943(t *testing.T) {
+ testenv.SkipIfOptimizationOff(t)
if n := testing.AllocsPerRun(10, func() {
runtime.KeepAlive(Verify("teststring", "test"))
}); n > 0 {