thread initial START:

master gives up running mutex
master waits for sentinel set
master akquires running mutex

thread akquires RUNNING_MUTEX
threads sets sentinel
thread suspends itself



thread SUSPEND:

thread gives up RUNNING_MUTEX
thread waits for sig_resume
thread akquires RUNNING_MUTEX
thread runs


thread END:

if other:
delete the other thread
if self:
thread gives up RUNNING_MUTEX
thread sends sig_resume to new active thread
thread self kills


thread YIELD
thread sends sig_resume to new active thread
thread suspends itself


time tick yield
tick handler sends SUSPEND to running thread
tick handler akquires RUNNING_MUTEX
tick handler sends sig_resume to new active thread
tock handler gives up RUNNING_MUTEX
tick handler ends

