qthread_disable_shepherd (qthread_shepherd_id_t shep);
qthread_enable_shepherd (qthread_shepherd_id_t shep);
Disabled shepherds cannot execute threads, and thus threads are actively migrated away from disabled shepherds. The migration is based on both distance and an estimate to "busyness" (based on the shepherd’s active queue length). Disabling a shepherd affects thread-placement decisions immediately, but the disabled shepherd may continue executing its current thread until it either blocks, yields, or exits. Once that thread stops executing, the disabled shepherd monitors its queue and rather than execute runnable threads, migrates runnable threads to nearby shepherds.
When a shepherd is re-enabled, it becomes available to run threads.
Table of Contents