Any noticeable performance gains in everyday use?
Any noticeable performance gains in everyday use?
I'm mostly glad it'll come with an updated WebAssembly, hopefully fixing this bug: https://bugs.chromium.org/p/v8/issues/detail?id=6204 which blocks Luwa from working in node (handwritten wasm has a tendency to run into things emscripten would not.. I expect the same vice versa)
Will also enjoy not having to use a TextEncoder/TextDecoder shim. Kind of weird that they went full out with Unicode there, last I recall browsers were moving towards only supporting utf8
Does anyone with high performance requirements writes JS? Isn't that setting yourself up for failure on the first step?
And yet there are a plethora of cases where all of those languages have been used with high performance requirements.
How about you needing performance AND web compatibility?
There's a big number of startups that used Node for their back-end, if it becomes faster without them having to rewrite their codebase, that's a win too.
It's possible to call into C from Node. So there's nothing stopping you from implementing performance-critical parts of a system with native code, and then invoking it from JavaScript.
You assume that "high performance" is the only requirement, so that it dictates everything.
People also have other requirements like "it has to run on a browser/on the web" etc AND high performance.
It's not like HPC people suddenly rush to use JS. But there are people targeting the web/node etc that DO want as high performance as they can get away with (e.g. web games).
We have JS that we use client side that we also use server side for Hadoop processing of data. So we didn't want to rewrite and maintain this large codebase in both Scala/Python and JS, so we ran Node on Hadoop.
No, it really isn't setting yourself up for failure if you do it correctly. Node really is quite fast; for our use case it rivaled Java 8 runtime in MR CPU time, the only downside is it had double the memory footprint. With enough hardware, memory is not too much of an issue.
I always say use the best tool for the job. And this usually means getting the requirements then laying out the solutions and picking the best solution out of the bunch.
It bothers me that people still think JavaScript is slow. I think JavaScript(engines) is the only languages which is getting significant performance improvement on monthly basis since V8 was introduced.
It is the abstraction people in JS/Frontend world people are used to, make it seem slow.
Read this article -> https://v8project.blogspot.com/2017/05/launching-ignition-an...
Basically TF is at parity on average but slower for code like the node core that was highly optimized to the particularities of crankshaft.
Hopefully npm 5.3.0 actually works since 5.0.0 was completely broken for me.
v7.10.0
Test suite for real world app
real 0m29.669s user 0m5.376s sys 0m0.356s
v8.3.0
Test suite for real world app
real 0m30.180s user 0m5.420s sys 0m0.220s
v7.10.0
Express Hello World
Requests per second: 6751.08 [#/sec] (mean)
HTTP Hello World
Requests per second: 13407.31 [#/sec] (mean)
v8.3.0
Express Hello World
Requests per second: 7734.33 [#/sec] (mean)
HTTP Hello World
Requests per second: 12601.42 [#/sec] (mean)