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

runtime: TestCgoExecSignalMask: got signal 15 received on thread with no signal stack #13881

Closed
ianlancetaylor opened this issue Jan 8, 2016 · 4 comments

Comments

@ianlancetaylor
Copy link
Contributor

I've seen this error in a few cases in the build logs. For example:

http://build.golang.org/log/cedd6f09c7a64e0c2cbf58eeafa7cacd3d1202aa
http://build.golang.org/log/8bf1813e1d26a4afc4e35bbec9c7e4f2620d2952
http://build.golang.org/log/a7d048adbb16d7e390badf070a59d17974ab8822
https://storage.googleapis.com/go-build-log/60b9f161/linux-arm_8b11f221.log (trybot run)

So far I have only seen it on GNU/Linux machines on arm or arm64 processors.

Sometimes it is signal 17 (SIGCHLD) instead of signal 15 (SIGTERM).

@ianlancetaylor ianlancetaylor self-assigned this Jan 8, 2016
@ianlancetaylor ianlancetaylor added this to the Go1.6 milestone Jan 8, 2016
@ianlancetaylor
Copy link
Contributor Author

I think I've found the problem. There seems to be a bug in cgocallback_gofunc in asm_arm.s and asm_arm64.s: they never call dropm. The effect is that a C thread can incorrectly have the g TLS variable set, causing Go to think that the signal stack should be set up, although it is not. If g were nil, as it should be, the code would have called badsignal. That sounds bad, but since the signal in question is SIGCHLD nothing actually happens.

@gopherbot
Copy link

CL https://golang.org/cl/18449 mentions this issue.

@mwhudson
Copy link
Contributor

BTW, would this be a 1.5.4 candidate if there was to be such a release?

@ianlancetaylor
Copy link
Contributor Author

Sure, I suppose so.

@ianlancetaylor ianlancetaylor modified the milestones: Go1.5.4, Go1.6 Jan 12, 2016
@golang golang locked and limited conversation to collaborators Jan 13, 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

3 participants