Ned Bass 3c6ed5410b Taskq locking optimizations
Testing has shown that tq->tq_lock can be highly contended when a
large number of small work items are dispatched.  The lock hold time
is reduced by the following changes:

1) Use exclusive threads in the work_waitq

When a single work item is dispatched we only need to wake a single
thread to service it.  The current implementation uses non-exclusive
threads so all threads are woken when the dispatcher calls wake_up().
If a large number of threads are in the queue this overhead can become
non-negligible.

2) Conditionally add/remove threads from work waitq

Taskq threads need only add themselves to the work wait queue if
there are no pending work items.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Issue #32
2012-01-19 14:42:49 -08:00
..
2010-01-08 09:37:54 -08:00
2011-02-25 16:56:22 -08:00
2010-07-20 13:30:40 -07:00
2011-01-12 11:38:05 -08:00
2010-05-17 15:18:00 -07:00
2010-05-17 15:18:00 -07:00
2012-01-19 14:42:49 -08:00
2010-07-20 13:30:40 -07:00