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
runtime: apparent deadlock in TestPanicSystemstack #49388
Comments
Possibly. I'll look into it. |
This is failing awfully consistently now, though I'm not sure why or what changed. |
I can reproduce this locally on tip now. |
OK! I have a stack trace from the subprocess that's getting stuck.
|
In the stack trace above, the problem is that goroutine 5 is runnable, but hasn't blocked itself on a lock yet. We see then also what appears to be a... mark background worker, trying to suspend something. If it's trying to suspend the one that's already blocked on a lock, then we have a problem. However an even bigger problem is: why is any part of the GC executing right now? The runtime is still running init functions at this point and the GC should not be enabled. |
Oh, haha. Naturally the GC is indeed enabled during user init tasks, just not the runtime ones. So it's fine for the GC to be running during init (which, uh, makes sense). I think this fix is straightforward. A test that involves goroutines deadlocking themselves on runtime locks definitely should not be running any garbage collections while they're deadlocking themselves. |
Hrm, actually, I don't have quite the whole picture here. Why doesn't goroutine 5 execute? It shouldn't really matter if the GC is running -- if the workers get stuck trying to suspend something, or a goroutine is trying to STW, it's really fine, as long as the two Maybe the problem is that Actually, this makes sense. Maybe a better fix here is to just increase |
Change https://golang.org/cl/361897 mentions this issue: |
greplogs --dashboard -md -l -e \(\?m\)io\\.ReadFull.\*\\n\\t.\*\\nruntime_test\\.TestPanicSystemstack
2021-11-04T23:35:26-256a8fc/linux-amd64-longtest
2021-11-04T20:42:35-1f9dce7/linux-amd64-longtest
(See previously #33626.)
@mknyszek, possibly another test issue relating to the GC pacing changes?
The text was updated successfully, but these errors were encountered: