Skip to content

misc/cgo/test: TestParallelSleep is unreliable on arm #4008

Closed
@davecheney

Description

@davecheney
What steps will reproduce the problem?

diff -r c552fb2b6a6c misc/cgo/test/issue1560.go
--- a/misc/cgo/test/issue1560.go        Sun Aug 26 11:17:55 2012 -0700
+++ b/misc/cgo/test/issue1560.go        Mon Aug 27 12:49:04 2012 +1000
@@ -40,7 +40,7 @@
        if runtime.GOARCH == "arm" {
                // on ARM, the 1.3s deadline is frequently missed,
                // so increase sleep time to 2s
-               sleepSec = 2
+               sleepSec = 20
        }
        start := time.Now()
        parallelSleep(sleepSec)

cd $GOROOT/misc/cgo/test
go test -c
while ./test.test ; do echo ; done

What is the expected output? What do you see instead?

expected: PASS

actual:

pando(~/go/misc/cgo/test) % while ./test.test ; do echo ; done
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
PASS

--- FAIL: TestParallelSleep (35.00 seconds)
_cgo_gotypes.go:751:    parallel 20-second sleeps slept for 34.997584 seconds
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
testLibgcc is disabled on ARM because 5l cannot handle thumb library.
FAIL

Please use labels and text to provide additional information.

This test fails on dual core ARM7 hosts. I cannot trigger the failure, even using the
original 2s timeout, on a single core ARM5 host.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions