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/cgo: TestParallelSleep test is flaky #6636

Closed
lexprfuncall opened this issue Oct 21, 2013 · 10 comments
Closed

cmd/cgo: TestParallelSleep test is flaky #6636

lexprfuncall opened this issue Oct 21, 2013 · 10 comments

Comments

@lexprfuncall
Copy link

I am getting the occasional test failure

--- FAIL: TestParallelSleep (1.56 seconds)
        issue1560.go:44: difference in start time for two sleep(1) is 562ms
        issue1560.go:48: parallel 1-second sleeps slept for 0.562000 seconds
@ianlancetaylor
Copy link
Contributor

Comment 1:

Labels changed: added priority-soon, go1.2maybe, removed priority-triage.

@ianlancetaylor
Copy link
Contributor

Comment 2:

What environment are you running in?  Is this from running the test in make.bash?  Is
your system heavily loaded?
On my Ubuntu laptop I'm seeing only
issue1560.go:44: difference in start time for two sleep(1) is 18ms
and the number is never higher than 20 even when I put load on the system.
I'm not sure how it's getting up to 562ms for you.

@lexprfuncall
Copy link
Author

Comment 3:

I have been running all.bash in a continuous loop for several days with GOGC set to 1. 
This has happened at least 3 times so far.  Here are the relevant lines from my log file
--- FAIL: TestParallelSleep (1.68 seconds)
        issue1560.go:44: difference in start time for two sleep(1) is 683ms
        issue1560.go:48: parallel 1-second sleeps slept for 0.683000 seconds
--- FAIL: TestParallelSleep (1.61 seconds)
        issue1560.go:44: difference in start time for two sleep(1) is 606ms
        issue1560.go:48: parallel 1-second sleeps slept for 0.606000 seconds
--- FAIL: TestParallelSleep (1.56 seconds)
        issue1560.go:44: difference in start time for two sleep(1) is 562ms
        issue1560.go:48: parallel 1-second sleeps slept for 0.562000 seconds

@rsc
Copy link
Contributor

rsc commented Oct 29, 2013

Comment 4:

Carl, what do you get when you run this:
cd $GOROOT/misc/cgo/test
GOGC=1 go test -run TestParallelSleep -v
It would be nice to know what the typical execution is, so that we can see how much of a
slowdown is happening in the cases that time out.
Three failures in 3+ days on a continuous loop is rare enough that I think we can leave
it for after Go 1.2.

Labels changed: removed go1.2maybe.

@rsc
Copy link
Contributor

rsc commented Oct 29, 2013

Comment 5:

Labels changed: added priority-later, removed priority-soon.

@rsc
Copy link
Contributor

rsc commented Nov 27, 2013

Comment 6:

Labels changed: added go1.3maybe.

@rsc
Copy link
Contributor

rsc commented Dec 4, 2013

Comment 7:

Labels changed: added release-none, removed go1.3maybe.

@rsc
Copy link
Contributor

rsc commented Dec 4, 2013

Comment 8:

Labels changed: added repo-main.

@alexbrainman
Copy link
Member

@rsc rsc added this to the Unplanned milestone Apr 10, 2015
@rsc
Copy link
Contributor

rsc commented Sep 26, 2016

Last update 2014. Assuming this is no longer an active concern.

@rsc rsc closed this as completed Sep 26, 2016
@golang golang locked and limited conversation to collaborators Sep 26, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants