Commits
Arthur Taylor committed 40234bb3e11
task scheduler: Wait for timeout, rather than fix amount in loop. Rather than spin the task thread loop every half second, calculate the longest the loop can wait an wait on the condition variable for that amount. This reduces unneeded spins of the loop and actually improves latency of some tasks. If a task becomes ready after having being iterated over, but before main loop body is entered, previously a delay of a half second always occured. Now, the loop will simply not wait and iterate again.