05-14-2013
4,673,
588
Join Date: Oct 2010
Last Activity: 1 February 2016, 3:35 PM EST
Location: Southern NJ, USA (Nord)
Posts: 4,673
Thanks Given: 8
Thanked 588 Times in 561 Posts
Sure, or something similar. If master has a queue to each thread, it can send tasks and stop requests. However, if you want a thread to suspend processing, it needs to be interrupted. Maybe all threads can service a SIGUSR1 to read a special queue or flag for such. Dispatching work without latency from excess buffering or lost cycles waiting on master or locks is one problem. Suspending and reactivating threads is another. Oh, BTW, lwp concurrent threads are a different problem than threads sharing a lwp.