Re:.NET and Node.JS – Performance Comparison
by Maarten88 on Friday March 29, 2013 @01:37PM
(#5461883)
I ran it too and came to the same conclusion: problem in the original comparison is that CPU usage of the node version never gets over 40% on my laptop, while the .NET version uses 100%. Using Array.sort() makes little difference. Adding threads to the node version does.
I think also adding threads to the .net version wont help it much; it already uses 100% CPU.
Re:.NET and Node.JS – Performance Comparison
by Guillaume86 on Friday March 29, 2013 @02:13PM
(#5462104)
Good idea to look at the CPU usage. To be complete I should show CPU/Memory usage under load but I've already spent enough time on this ;).
The big performance hit for the node version is the float conversion.
Multithreaded .NET version is a bit harder to write because usually this work is delagated to ASP.NET/IIS.
UPDATE: the .NET version is actually already multithreaded because of the Task system, so Node.JS seems to be actually faster in this scenario...