4 ms·
My understanding is, that Firefox Quantum is not faster due to any additional rust parts, but because the team focused on performance optimization across the en
by 3ds 9y ago
My understanding is, that Firefox Quantum is not faster due to any additional rust parts, but because the team focused on performance optimization across the entire codebase.
The only big rust component was introduced a couple of releases ago: Stylo.
Once Webrender is in Firefox, a serious chunk of Firefox will be written in Rust.
- mintplant 9y agoThis is incorrect, Stylo is new in 57 and part of the speed boost of Quantum.
- rkangel 9y agoMy understanding was the Stylo is released to the production channel today, and it is a major part of the performance boost. "Quantum" as a term covers a large number of areas, this blog post covers it well: https://hacks.mozilla.org/2017/11/entering-the-quantum-era-how-firefox-got-fast-again-and-where-its-going-to-get-faster/ https://hacks.mozilla.org/2017/11/entering-the-quantum-era-h...
- gsnedders 9y agoStylo is a big perf jump, but so are many of other changes. It isn't solely replacing things with Rust that has made it fast.
- metajack 9y agoStylo is about 10x faster than the old style system on a four core machine, and about 4x faster than Chrome's style system. This feature alone is worth 30% of initial page load time on amazon and youtube. So yes, Quantum is faster as a direct result both of Rust code, and of Rust's memory-safety-makes-parallelism-practical features. That is not the only source of performance improvement in Quantum though. Also, Quantum isn't yet getting the full benefits possible from this code for a few reasons. Firefox 57 uses Stylo for content, but not yet for chrome, which will be coming in a later release. In Servo, CSS is parsed off the main thread, but in Quantum it is not yet (will be done in a future release). Servo pipelines style resolution and frame construction (basically after the top down pass to deal with the style cascade, we go back up the tree bottom up constructing the layout data structures), and Quantum does not yet do this. Lastly, cross-language inlining is missing which would allow inlining FFI calls. Servo doesn't have this issue since all the driver and layout code is also in Rust.