[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: new Cohttp interface progress



On Wed, Aug 08, 2012 at 02:01:58AM +0100, Jonathan Ludlam wrote:
> 
> On 6 Aug 2012, at 23:53, Anil Madhavapeddy wrote:
> 
> > 
> > You could also build a version of IO.M that uses native threads (where
> > type t would be a dummy type and not actually hold any state).
> > 
> 
> I bet this would introduce all sorts of problems because you no longer
> can assume that a block of code with no IO.bind in will run atomically.
> I'm sure I've seen a few places in the code that make that assumption.

We need to be careful, but I think it'll still work because there is
exclusive ownership on the underlying channel.  If every thread has a
single channel allocated to it, and locks around that usage, it'll work.
I'll knock one up later to make sure this is actually true :-)

-- 
Anil Madhavapeddy                                 http://anil.recoil.org



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.