-
Notifications
You must be signed in to change notification settings - Fork 18k
"fatal error: casgstatus: bad incoming values" in runtime package #49513
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
Comments
Note that Go 1.14 is no longer supported. I agree that this output is simply impossible. And nobody else is reporting this. That suggests a hardware problem, such as bad memory. Has this happened on more than one machine? |
I don't think it's a hardware problem, the same problem appears on two different machines and different applications. func casgstatus(gp *g, oldval, newval uint32) {
if (oldval&_Gscan != 0) || (newval&_Gscan != 0) || oldval == newval {
systemstack(func() {
print("runtime: casgstatus: oldval=", hex(oldval), " newval=", hex(newval), "\n")
throw("casgstatus: bad incoming values")
})
}
// ...
} Here are local variables, which should not be caused by data competition. I have just consulted other colleagues and they have encountered similar problems. If we upgrade the tool chain, it will have too much impact and we need to reassess the risk. So I would like to come to github to ask if there are any relevant debug means. |
Actually, none of those builders are showing the same problem. They happen to have the same string, but for entirely different reasons. Which is good, because the problem simply can't happen. I'm sorry, I don't know how to debug this. My only suggestion would be to look closely at the generated code to see how this could happen, since as we both agree the Go code can't produce this result. Is it possible that you have a corrupt compiler that is somehow generating bad code for this case? |
Timed out in state WaitingForInfo. Closing. (I am just a bot, though. Please speak up if this is a mistake or you have the requested information.) |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
I don't know, This problem has only appeared twice in our program this year.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
Nothing
What did you expect to see?
Stable operation of software
What did you see instead?
There was a fatal error: casgstatus: bad incoming values.
I reviewed the code and, based on the printed oldVal and newval, guessed that it should not be possible to enter this branch.
I wonder if there is any effective debugging for this kind of problem
The text was updated successfully, but these errors were encountered: