6 ms·
Traditional JavaScript benchmarks
- BlackFingolfin 10y ago"It is probably fair to say that JavaScript is the most important technology these days when it comes to software engineering." Uhh ... no?
- sametmax 10y ago+1 "JS is the only API we currently have to use one of the most popular plateform we have" would be more accurate. And it's a terrible API. I can't wait for webassembly.
- k__ 10y agoUhh ... yes. It didn't say it's the best, which it probably isn't.
- debaserab2 10y agoIt's maybe fair to say it's the most important technology when it comes to web development. The software engineering world is much bigger than just web development, though.
- SomeCallMeTim 10y agoJavaScript is important in: * Web Development is obvious, sure * Cross platform app development: React Native, NativeScript, Electron, nw.js, and others are extremely powerful, arguably among the best cross platform solutions, and all are gaining in popularity * Server development. NodeJS is hard to ignore because it's fast, easy to develop in, and has the amazing (if sometimes frustrating) NPM ecosystem. Software engineering is bigger than that trifecta, but you probably hit the 80% mark if you count all application, web, and server code development. JavaScript is making some inroads into embedded, but it's not as ideal for embedded work, except as a control language from the outside, so I'm not as bullish on JavaScript there. Throw in TypeScript and a good linter and you have a really strong, flexible, dynamic-yet-statically-typed environment that you can use to hit the (estimated) 80% mark. It really does live at a sweet spot in productivity and software engineering, if you ignore the anti-JavaScript snobs. [1] [1] Disclaimer: I was an anti-JavaScript snob as recently as about 5 years ago. My background is in games, drivers, C++, assembly language, several other scripting languages, and writing native apps. Things that changed include: 1) Me, in that I gave JavaScript, and later TypeScript a try, 2) I learned to love linters and transpilation, 3) The ecosystem exploded and the tools we have now, including VS Code and build tools like gulp, not to mention the built-in debuggers in every major browser, are now amazing, and 4) JavaScript and TypeScript themselves evolved and upgraded until they were actually both very good languages.
- fnordsensei 10y agoI guess it comes down to what you mean by "important". I for one hope that airplanes, power plants and medical machinery are all programmed with something else.
- lttlrck 10y agoIf the author had said the same thing about <insert any language> that would have been wrong too...
- Skunkleton 10y ago
- paulddraper 10y agoGosh, how do you even judge that.... If JS is super important, does that make C++ (the most common implementation language for JS runtimes) super-duper important? Willing to bet $100 that there are more projects developing with Git than JS. --- Actually wait...I GOT IT: the most important technology these days when it comes to software engineering is the microprocessor.
- acqq 10y agoSome very good examples and a good explanation of the reasoning behind the previous and the current optimizations of the JavaScript execution infrastructure. For the context, from the "about" page of the author, he: "joined Google to work on the V8 JavaScript Engine in the Munich office, where" he's "currently working as tech lead for the JavaScript execution optimization team."
- kalleboo 10y agoI apologize if this is an uninformed question, but are there any popular browser benchmarks out there? I'm sure that JS benchmarks are useful to browser developers and those who want JS to be the next general application platform, but as a user, I'm currently sticking to Safari since things like battery life and scrolling performance on mainly document-oriented pages are still more important to me.
- hoschicz 10y agothe author mentions speedometer. It tests everything a browser needs to load and use a web app - styling, DOM parsing, JS...
- gravypod 10y agoAll of these changes that the author is making are changes that the compiler should be generating. Unless you work in the embeded systems I don't expect people to have done or needed the % 2048 trick.
- sambe 10y agoThe author is writing the compiler (and modifying it to make these changes). What do you mean exactly?
- gravypod 10y agoI'm just wowed by this not already being part of V8. What else have they been doing? I know that V8 has some amazing performance characteristics and if they aren't from doing things that C compilers have been doing for years, then what are these speed boosts coming from?
- sambe 10y agoIt might help to read a bit more closely. A lot of the optimisations being discussed were already added years ago; the point is that they are not as useful in real-world usage as they are in benchmarks (or, in fact, disadvantageous). JIT compiling a highly dynamic language is quite a different task than AOT compiling a statically typed language. Bit-twiddling tricks are unlikely to be the biggest concern. Try starting with the obvious like https://en.wikipedia.org/wiki/Just-in-time_compilation https://en.wikipedia.org/wiki/Just-in-time_compilation
- zspitzer 10y agoIs there a benchmark which tests boring real world usage? The web is littered with people complaining about the performance of dynamically adding rows to tables, especially in IE. The good news is that the next version of Edge 15 has some really good DOM performance improvements. https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/10152783/ https://developer.microsoft.com/en-us/microsoft-edge/platfor...
- chrisseaton 10y agoBut that's not the JS implementation - that's the DOM and layout implementation. Faster JS won't improve that.
- deleted 10y ago[deleted]
- deleted 10y ago[deleted]
- deleted 10y ago[deleted]
- deleted 10y ago[deleted]
- deleted 10y ago[deleted]
- deleted 10y ago[deleted]
- nabaffc 10y agoI'm going to say something about js benchmarks. Every time you say "Firefox sucks because it's slow" someone will come and say "that is false, look at these js benchmarks! We're in line with other browsers!". But then those benchmarks omit the stuff that actually matters, stuff that Firefox simply sucks at, like DOM manipulation..
- maaaats 10y agoThe part about optimizing for the Mandreel-test by skipping some initialization has gone full circle, as this is now exploited by developers. https://github.com/nolanlawson/optimize-js https://github.com/nolanlawson/optimize-js