Mozilla is promising more speed improvements in the forthcoming Firefox 58, building on the new engine introduced in Firefox 57, known as Quantum, which is better at exploiting multicore CPUs.

Firefox 58 will be faster at compiling WebAssembly code coming in from the network thanks to ‘streaming compilation’ — which allows code to be compiled and downloaded in parallel — and a faster two-tiered compiler.

WebAssembly code works with JavaScript to offer near-native performance to web apps. Safari and Edge recently added support for WebAssembly, broadening existing support for the .wasm format from Chrome and Firefox.

Tech Republic: Why Firefox Quantum could take Chrome’s position as the king of browsers

Streaming compilation and the new compiler allow Firefox 58 to compile code faster than the network can deliver packets, thus removing the main bottleneck to faster page loads that involve downloading a lot of JavaScript, according to Lin Clark, an engineer on the Mozilla Developer Relations team.

In the past, web performance was constrained by the network, Clark said, but the new bottleneck is the CPU and the main thread. Firefox 58 takes the burden off the main thread and makes better use of a CPU’s time.

Mozilla says the added speed in Firefox 58 comes partly from a new compiler that loads WebAssembly files faster than the equivalent-sized JavaScript files.


Image: Mozilla

The new compiler in Firefox 58 with streaming compilation…

[SOURCE]