Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/go: testing on arm64 often time-out #35525

Closed
shawn-xdji opened this issue Nov 12, 2019 · 1 comment
Closed

cmd/go: testing on arm64 often time-out #35525

shawn-xdji opened this issue Nov 12, 2019 · 1 comment

Comments

@shawn-xdji
Copy link
Contributor

@shawn-xdji shawn-xdji commented Nov 12, 2019

What version of Go are you using (go version)?

$ go version
go version devel +c2edcf4b12 Tue Nov 12 01:09:40 2019 +0000 linux/arm64

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="arm64"
GOBIN=""
GOCACHE="/home/xiaji01/.cache/go-build"
GOENV="/home/xiaji01/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="arm64"
GOHOSTOS="linux"
GOINSECURE=""
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/home/xiaji01/.go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/home/xiaji01/local/go.latest"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/home/xiaji01/local/go.latest/pkg/tool/linux_arm64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/home/xiaji01/local/go.latest/src/go.mod"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build855348932=/tmp/go-build -gno-record-gcc-switches"

What did you do?

build go with 'src/all.bash'

What did you expect to see?

both building and testing pass

What did you see instead?

The following testcases often failed due to time-out (10m), it's likely caused by heavy I/O slowing down the testing the target machine may run up to 200+ cases in parallel, if setting GOMAXPROCS to smaller value the issue is gone (verified by multiple iterations), can we increase the time-out value?

TestStackMem
TestStackGrowth
TestSemaHandoff

=== RUN TestParallelRWMutexReaders
--- PASS: TestParallelRWMutexReaders (0.00s)
=== RUN TestRWMutex
--- PASS: TestRWMutex (0.07s)
=== RUN TestSemaHandoff
panic: test timed out after 10m0s

goroutine 30958094 [running]:
panic(0x203300, 0x4000530000)
/home/xiaji01/local/go.latest/src/runtime/panic.go:1054 +0x404 fp=0x400038bf70 sp=0x400038bec0 pc=0x43704
testing.(*M).startAlarm.func1()
/home/xiaji01/local/go.latest/src/testing/testing.go:1422 +0xc8 fp=0x400038bfd0 sp=0x400038bf70 pc=0xe9158
runtime.goexit()
/home/xiaji01/local/go.latest/src/runtime/asm_arm64.s:1148 +0x4 fp=0x400038bfd0 sp=0x400038bfd0 pc=0x782a4
created by time.goFunc
/home/xiaji01/local/go.latest/src/time/sleep.go:171 +0x40

goroutine 1 [chan receive, 4 minutes, locked to thread]:
runtime.gopark(0x275050, 0x400310d8b8, 0x40002c170e, 0x2)
/home/xiaji01/local/go.latest/src/runtime/proc.go:304 +0xd0 fp=0x40002c1ac0 sp=0x40002c1aa0 pc=0x46230
runtime.chanrecv(0x400310d860, 0x40002c1bd8, 0x4000000101, 0xe57f4)
/home/xiaji01/local/go.latest/src/runtime/chan.go:563 +0x2c4 fp=0x40002c1b50 sp=0x40002c1ac0 pc=0x174f4
runtime.chanrecv1(0x400310d860, 0x40002c1bd8)
/home/xiaji01/local/go.latest/src/runtime/chan.go:433 +0x28 fp=0x40002c1b80 sp=0x40002c1b50 pc=0x171d8
testing.(*T).Run(0x40006125a0, 0x26394d, 0xf, 0x276b20, 0x5dca4701)
/home/xiaji01/local/go.latest/src/testing/testing.go:1006 +0x2e0 fp=0x40002c1c30 sp=0x40002c1b80 pc=0xe5810
testing.runTests.func1(0x4000388000)
/home/xiaji01/local/go.latest/src/testing/testing.go:1247 +0x74 fp=0x40002c1c80 sp=0x40002c1c30 pc=0xe9004

@bcmills

This comment has been minimized.

Copy link
Member

@bcmills bcmills commented Nov 12, 2019

If the tests are timing out due to a slow builder, but you don't think they're actually deadlocked, you can set GO_TEST_TIMEOUT_SCALE.

(See #10314 and CL 9223.)

@bcmills bcmills closed this Nov 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.