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

test: mallocfin sometimes fails on Plan 9 #7480

Closed
0intro opened this issue Mar 6, 2014 · 5 comments
Closed

test: mallocfin sometimes fails on Plan 9 #7480

0intro opened this issue Mar 6, 2014 · 5 comments
Labels
FrozenDueToAge OS-Plan9 Suggested Issues that may be good for new contributors looking for work to do.
Milestone

Comments

@0intro
Copy link
Member

0intro commented Mar 6, 2014

What steps will reproduce the problem?

When running the Go builder on Plan 9, the mallocfin test
sometimes fails on while running "go run run.go" in the
test directory.

See http://build.golang.org/log/eca9f872b862cfc1daf9d947b4d049db52a9c898

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

# go run run.go -- mallocfin.go
incorrect output
not enough finalizing: 250 / 250
panic: fail

goroutine 16 [running]:
runtime.panic(0x258c0, 0x1017c0d0)
    /tmp/gobuilder/plan9-386-cnielsen-363a4ef7e011/go/src/pkg/runtime/panic.c:250 +0xab
main.main()
    /tmp/gobuilder/plan9-386-cnielsen-363a4ef7e011/go/test/mallocfin.go:75 +0x229

goroutine 32 [finalizer wait]:
runtime.park(0x10410, 0x5712c, 0x565e7)
    /tmp/gobuilder/plan9-386-cnielsen-363a4ef7e011/go/src/pkg/runtime/proc.c:1378 +0x61
runtime.parkunlock(0x5712c, 0x565e7)
    /tmp/gobuilder/plan9-386-cnielsen-363a4ef7e011/go/src/pkg/runtime/proc.c:1394 +0x3b
runfinq()
    /tmp/gobuilder/plan9-386-cnielsen-363a4ef7e011/go/src/pkg/runtime/mgc0.c:2531 +0x71
runtime.goexit()
    /tmp/gobuilder/plan9-386-cnielsen-363a4ef7e011/go/src/pkg/runtime/proc.c:1452
exit status: 'mallocfin 251460: 2'

FAIL    mallocfin.go    18.961s
exit status: 'run 250578: 1'
76.51u 65.50s 507.14r    go run run.go  # status= 1
@ality
Copy link
Member

ality commented Mar 8, 2014

Comment 1:

The error message in this test is wrong because nfinal can continue being incremented
after breaking out of the loop. If you save nfinal into a temporary and use that in the
print, the failure is always "not enough finalizing: 0 / 250" which means the finalizers
are not being run in time. I'm not sure why that is yet.
This failure seems to happen pretty frequently. I've run the test a lot and in some
iterations, it happens 1 out of every 5 times and others it's 1 in 20.
Still investigating ...

Status changed to Accepted.

@dvyukov
Copy link
Member

dvyukov commented Mar 11, 2014

Comment 2:

I do not believe that 2 rounds of finalizer can run in the period between break and
println (there is basically nothing there).
Maybe it's an issue with code generation (nfinal is not re-read in the loop).

@rsc
Copy link
Contributor

rsc commented Apr 14, 2014

Comment 3:

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

@bradfitz
Copy link
Contributor

Comment 4:

Labels changed: added os-plan9.

@rsc
Copy link
Contributor

rsc commented May 9, 2014

Comment 5:

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

@0intro 0intro added accepted Suggested Issues that may be good for new contributors looking for work to do. labels May 9, 2014
@rsc rsc removed the os-plan9 label Apr 10, 2015
@rsc rsc added this to the Unplanned milestone Apr 10, 2015
@0intro 0intro self-assigned this Jul 30, 2015
@0intro 0intro closed this as completed Jul 30, 2015
@golang golang locked and limited conversation to collaborators Aug 5, 2016
@rsc rsc unassigned 0intro Jun 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge OS-Plan9 Suggested Issues that may be good for new contributors looking for work to do.
Projects
None yet
Development

No branches or pull requests

6 participants