CLock is potentially a busy lock(!) fast if you expect very short pauses
and slow otherwise. but the op you are doing is el cheapo and so exactly
what we use it for.

Thanks for the patch and keep it coming!

On Fri, 2013-11-15 at 00:24 -0800, Roman Votyakov wrote:
> In src/shogun/machine/gp/InferenceMethod.cpp:
> 
> > @@ -31,6 +31,9 @@ struct GRADIENT_THREAD_PARAM
> >  	CMap<TParameter*, SGVector<float64_t> >* grad;
> >  	CSGObject* obj;
> >  	TParameter* param;
> > +#ifdef HAVE_PTHREAD
> > +	pthread_mutex_t* lock;
> 
> Oops, sorry, I forgot about CLock.
> I don't understand the second question. Could you please explain a
> little bit? What do you actually mean?
> 
> —
> Reply to this email directly or view it on GitHub.
> 

-- 
For the one fact about the future of which we can be certain is that it
will be utterly fantastic. -- Arthur C. Clarke, 1962