It can, but there is a futex value per lock. If the task_struct had a
list of held futex locks (as it does for pi futex locks) the
deschedule() path could walk that and mark the FUTEX_OWNER_SLEEPING bit.
This appears to be 1 bit per task instead of 1 bit per lock. Also, the
value is thread-specific... so how would a potential waiter be able to
determine if the owner of a particular lock was running or not with this
method? ... maybe I'm missing some core bit about TLS... are you
talking about pthread_key_create() and pthread_getspecific() ?
Thanks,
--
Darren Hart
IBM Linux Technology Center
Real-Time Linux Team
--