[sheepdog] [PATCH] sheep: introduce 'short thread' to worker threads

MORITA Kazutaka morita.kazutaka at lab.ntt.co.jp
Fri Jun 29 10:44:59 CEST 2012


At Fri, 29 Jun 2012 14:01:21 +0800,
Liu Yuan wrote:
> 
> On 06/29/2012 01:41 PM, Liu Yuan wrote:
> > This patch introduces *short thread* abstraction that is created on demand and destroyed
> > after serving the work when sheep run short of gateway or io threads, aiming to
> > solve two problems:
> > 
> >  1. timeout of IO requests from guests. With on-demand short threads, we guarantee
> >     that there is always one thread available to execute the request ASAP.
> >  2. system halt for corner cases that all gateway and io threads are executing
> >     local requests that ask for creation of another thread to execute the request
> >     and sleep wait for response.
> 
> Hi Kazum, I am thinking of making threads for gateway and io threads
> fully dynamic. How do you think of it?  I think pthread_cond is as
> expensive as pthread_create. Fully dynamic threads will allow better
> scalability.

Does the approach really show better performance and scalability than
the current workqueue model with your short thread patch?  I'd like to
see the performance number before accepting the change.

Thanks,

Kazutaka



More information about the sheepdog mailing list