add comment about Signal unsoundness

This commit is contained in:
vyzo 2023-03-30 18:13:08 +03:00
parent 54a80a8a97
commit 7b4e68249a

View File

@ -125,6 +125,8 @@ func (e *executionEnv) putToken(token *executionToken) {
e.available++
e.reserved += token.reserved
// Note: Signal is unsound, because a priority token could wake up a non-priority
// goroutnie and lead to deadlock. So Broadcast it must be.
e.cond.Broadcast()
metricsDown(metrics.VMExecutionRunning, token.lane)