Re: [PATCH 35/40] fscache: convert object to use workqueue instead of slow-work

David Howells
2010-02-18T11:51:41Z

Tejun Heo <tj@kernel.org> wrote:

> The waiting workers are woken up in slow_work_enqueue() when a new
> work is enqueued regardless of how many workers are currently in use,
> right? So, it ends up yielding on any queue activity rather than only
> under resource pressure.

It depends how you define resource pressure, I suppose. There's someone now
waiting for the resource, and there's someone blocking that resource who can
yield it as they're waiting on something else. The question is if it's
cheaper to create a new thread, assuming we're under the limit, or if it's
cheaper to steal someone else's thread?

David