3 ms·
I’d rather hear what Lars Bak has to say. He’s the one in charge of the JS engine most of us use…
by pipeline_peak 3y ago
I’d rather hear what Lars Bak has to say. He’s the one in charge of the JS engine most of us use…
- olliej 3y agoTo my knowledge Bak has not been involved in V8 for many years, but also from my direct experience the overwhelming majority of JS executed is dominated by latency rather than through put (which is Kling’s point) The original v8 was a significant change in that it showed that it is possible to optimize - to machine code - js in a way that offers sufficient perf to make it an enabler of more complex code. however that came at a significant increase in real world page load performance. Dealing with that latency regression was a significant challenge when originally introducing a JIT to JSC. Even today it is amazing how little emphasis is seemingly placed on interpreter performance by chrome and Firefox, as it dominates page load performance and latency for almost all real world pages. (I’m actually somewhat curious what % of js source seen by engines ever actually reaches a point where gains from native codegen cover the runtime cost of said codegen)
- lttlrck 3y agoGoogle has spent huge efforts optimizing page start up times, this overview is from late last year. Maybe not "interpreter performance" per se, but it's in the area and focused on page load time. https://v8.dev/blog/maglev https://v8.dev/blog/maglev
- olliej 3y agoEvery browser devotes huge amounts of effort to PLT because that is the place where performance matters for most sites. JS interpreter perf is a significant part of the latency, which is why it's weird to me that so little effort is placed into that vs the ever increasing complexity of JIT optimizations that are only important for a minority of websites. There are also security reasons for improving interpreter perf as it gives you the option to have the JIT disabled for more processes (at the extreme there's iOS "lockdown" mode which disables the JITs everywhere)
- paddim8 3y agoAndreas worked on performance for Safari and has also talked to several other people who have worked with the JavaScript engines of major browsers and they have all come to the same conclusion.