runtime: checkdead throws with lock held results in deadlock #59758
Labels
compiler/runtime
Issues related to the Go compiler and/or runtime.
FrozenDueToAge
NeedsFix
The path to resolution is known, but the work has not been done.
Milestone
What version of Go are you using (
go version
)?1.20.3
Does this issue reproduce with the latest release?
yes
What did you do?
schedtrace
and/orsheddetail
inGODEBUG
checkdead
on runnable G's with no running M's (see runtime: checkdead fires due to suspected race in the Go runtime when GOMAXPROCS=1 on AWS #59600)What did you expect to see?
What did you see instead?
Additional details
In the
checkdead
function context, the lock is held by the caller. Up the stack, following athrow
,schedtrace
will try to acquire the scheduler lock, resulting in a double lock.The text was updated successfully, but these errors were encountered: