That's a great post Paddy, lots of the gore on the issue although I maybe 
don't totally agree on points 1 & 3. Most of process is trivial to 
virtualise, it's just an effort thing but you are right to point out the 
concern. But then maybe I am missing the point that your concern is over 
native modules getting inconsistent views of things shared in process? 
Signals I have not dealt with yet beyond noting the problem in libev with 
handling them on a non-default loop. I would think its fixable but haven't 
implemented it yet.
>
>
The performance gains I am seeing are largely down to avoiding OS costs 
in synchronization. When I first profiled thread message passing it was 
quicker than the cluster version, by about x5 from memory, the bottleneck 
was the OS overhead of using an async send. I recoded to avoid entering the 
OS via atomics and the performance gain shot up as you would expect. Now I 
have always done this kind of optimization in threaded environments so I 
know the story, what I don't know of is can you reliably do this cross 
platform with process shared memory and if you wanted to how would you cope 
with the memory management aspects of that. If that 
was solvable then arguably threads don't make any sense, although they may 
still be the lesser of two evils from a pragmatic point of view.

I decided to pull my work off github as its as done as I needed it to be at 
this point and clearly there is little wider interest without a lead 
feature. I was always more interested in pushing on the shared storage 
which is why I got involved with threads to start with so I am setting off 
down that route.

Kev

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to nodejs@googlegroups.com
To unsubscribe from this group, send email to
nodejs+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to