3 ms·
Well hold on a second. The JS impl that you're talking about uses a minimal custom runtime (https://github.com/just-js/just https://github.com/just-js/just) tha
by hombre_fatal 3y ago
Well hold on a second. The JS impl that you're talking about uses a minimal custom runtime (https://github.com/just-js/just https://github.com/just-js/just) that you would never use—it barely implements JS. It's basically only used for this benchmark. It doesn't make sense to compare that to Go when we're talking about Javascript vs. Go performance.
Scroll down to the "nodejs" entry for a more realistic comparison.
- ffsm8 3y agoFeel free to switch to json serialization and the the same pattern repeat with uwebsockets.js. I'm not saying that JS is "just as fast as golang" generally. My argument is specifically that it's optimized to a degree that there are cases in which JS, an interpreted language, does end up on top. The same applies to erlang and it's optimization for efficient concurrency. On average you'll likely get better performance with go, but depending on the workload the results can differ