On Sun, Mar 24, 2013 at 1:47 AM, Ken <[email protected]> wrote:

> Off the top of my head (without bothering to dig into the code):
>
>    - there's some O(N) operation in node relating to number of workers
>    like looking them up in an array
>    - the operating system is introducing latency, e.g. due to context
>    switching or paging.  Have you tried tracking all the potentially relevant
>    system performance stats in parallel with your runs to see if any of them
>    spike?
>
> Yes, strace -c seems to suggest that write() itself gets slower:
https://gist.github.com/baudehlo/5204847


> I'm curious why sending messages is the key performance metric?  The
> reason I suggested an alternate benchmark is because the difference between
> sending 220K/s and 180K/s would only seem to matter if the receiver could
> somehow do more net work at the higher rate.  I'm struggling to imagine
> what task it could perform that wouldn't make that difference immaterial.
>

That performance is beyond what I personally need, for sure. The results
are more just a curiosity.

But imagine a system that needs to perform millions of operations per
second (think of stock trading systems). They are currently built in Java
or C/C++ and use threads for performance to ensure scalability on multi-CPU
boxes. They use systems like this one which can perform 130M
operations/sec:
http://psy-lob-saw.blogspot.ca/2013/03/single-producerconsumer-lock-free-queue.html-
I was mostly just curious to see what level of ops/sec cluster's child
node communication protocol could achieve (and yes I realize why it has so
much higher overhead - I wasn't expecting close to 130M/s). Clearly
cluster.send() isn't the right way to build that in Node, but after I got
the results I just wanted to know why it slows down so dramatically with
more nodes.

Matt.

-- 
-- 
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 [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to