internal/bytealg: strings test fails on ppc64le/p9 on certain random strings
#!watchflakes
post <- pkg == "strings" && test == "TestIndexRandom"
What version of Go are you using (go version)?
master go1.20-50557edf10
Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (go env)?
go env Output
$ go env GO111MODULE="" GOARCH="ppc64le" GOBIN="" GOCACHE="/home/archana/.cache/go-build" GOENV="/home/archana/.config/go/env" GOEXE="" GOEXPERIMENT="" GOFLAGS="" GOHOSTARCH="ppc64le" GOHOSTOS="linux" GOINSECURE="" GOMODCACHE="/home/archana/go/pkg/mod" GONOPROXY="" GONOSUMDB="" GOOS="linux" GOPATH="/home/archana/go" GOPRIVATE="" GOPROXY="https://proxy.golang.org,direct" GOROOT="/home/archana/Go_master/go" GOSUMDB="sum.golang.org" GOTMPDIR="" GOTOOLDIR="/home/archana/Go_master/go/pkg/tool/linux_ppc64le" GOVCS="" GOVERSION="devel go1.20-50557edf10 Thu Oct 27 10:37:01 2022 +0000" GCCGO="gccgo" GOPPC64="power9" AR="ar" CC="gcc" CXX="g++" CGO_ENABLED="1" GOMOD="/home/archana/Go_master/go/src/go.mod" GOWORK="" CGO_CFLAGS="-O2 -g" CGO_CPPFLAGS="" CGO_CXXFLAGS="-O2 -g" CGO_FFLAGS="-O2 -g" CGO_LDFLAGS="-O2 -g" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build3329760993=/tmp/go-build -gno-record-gcc-switches"
What did you do?
There is a random failure seen recently in the Go build dashboard under ppc64le/power9. The timing of this error seems to be related to the CL 443058 as it does not occur with setting GODEBUG=randautoseed=0.
--- FAIL: TestIndexRandom (0.01s) strings_test.go:268: Index(999f2xmimunbuyew5vrkla9cpwhmxan8o98ec,98ec) = -1; want 33 FAIL FAIL strings 1.575s
Upon running the strings test multiple times with random inputs, it appears that the test fails for some number of cases.
What did you expect to see?
The strings test should pass
What did you see instead?
The strings test fails for a subset of the random inputs tested
@bcmills
CC @golang/ppc64
Change https://go.dev/cl/446135 mentions this issue: internal/bytealg: Fix bug in index function for ppc64le/power9
Found new dashboard test flakes for:
#!watchflakes
post <- pkg == "strings" && test == "TestIndexRandom"
2022-10-27 01:24 linux-ppc64le-power9osu go@612bb34a strings.TestIndexRandom (log)
--- FAIL: TestIndexRandom (0.01s)
strings_test.go:268: Index(999f2xmimunbuyew5vrkla9cpwhmxan8o98ec,98ec) = -1; want 33
I think gopherbot reopened this against failure @archanaravindar already observed and committed a fix for yesterday.
@archanaravindar does this fix need backported to go1.19?