You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The problem is that, while wait_timeouttemporarily blocks the thread, it's not permanent, and so shouldn't count as deadlock.
We already knew that our modeling of wait_timeout wasn't complete because it doesn't test the timeout case, but this test shows the effects of such incompleteness—spurious failures.
We need to have a better notion of "blocked but can be unblocked". One cheap-ish idea would be for wait_timeout to spawn another (internal to Shuttle) "thread" that, when executed, causes the thread blocked in wait_timeout to unblock and return timeout. This would let the scheduler "naturally" decide when to trigger a timeout rather than us having to build any fancy time handling into the scheduler itself.
The text was updated successfully, but these errors were encountered:
Shuttle complains that this test deadlocks, but in reality it doesn't:
The problem is that, while
wait_timeout
temporarily blocks the thread, it's not permanent, and so shouldn't count as deadlock.We already knew that our modeling of
wait_timeout
wasn't complete because it doesn't test the timeout case, but this test shows the effects of such incompleteness—spurious failures.We need to have a better notion of "blocked but can be unblocked". One cheap-ish idea would be for
wait_timeout
to spawn another (internal to Shuttle) "thread" that, when executed, causes the thread blocked inwait_timeout
to unblock and return timeout. This would let the scheduler "naturally" decide when to trigger a timeout rather than us having to build any fancy time handling into the scheduler itself.The text was updated successfully, but these errors were encountered: