kvark / choir

Task Orchestration Framework
MIT License
52 stars 3 forks source link

Threads going to sleep are sometimes not considered parked #7

Closed kvark closed 2 years ago

kvark commented 2 years ago

When scheduling a task, the logic checks if any threads are parked, and tries to wake them up. It may happen that at this time the threads are just about to sleep, and they aren't sleeping yet, and their parked mask may or may not be updated. This leads to a freeze, where there is work but no threads are awake.

kvark commented 2 years ago

Fixed by a422666d6107c932ca1abe085fc47807238dd041