Jump to content

Rust Programming Language Takes More Central Role in Firefox Development


vissha

Recommended Posts

Rust Programming Language Takes More Central Role in Firefox Development

 

Rust.jpg

 

Starting with the release of Firefox 54, the Rust programming language will take a bigger role in the Firefox browser, as more and more components will work on top of this new technology developed in the past years by the Mozilla Research team.

 

For people unfamiliar with Rust, this is a new programming language developed by a Mozilla employee, which the Foundation officially started to sponsor beginning with 2009.

 

In simple terms, Rust is a safer version of programming languages like C and C++, the languages at the base of Firefox and most of today's desktop software.

 

Applications written in Rust have fewer memory-related errors and are safer to use thanks to the way the language was designed.

 

Mozilla shipped first Rust component in Firefox 48

 

After seven years of working on Rust, Mozilla shipped the first Rust component with Firefox in August 2016, when the language was used to rewrite the browser's multimedia stack, the module that deals with rendering audio and video files. At the time, Mozilla reported they had zero issues during tests.

 

Since then, Mozilla engineers have been slowly replacing more and more Firefox core components with Rust-based alternatives.

 

According to an entry in the Mozilla bug tracker, there's so much Rust code in the Firefox core that starting with Firefox 54, Mozilla developers will need to have the Rust compiler installed on their devices in order to compile a binary version of Firefox.

 

Mozilla might lose some Firefox users

 

According to Firefox developer Ted Mielczarek and others, this will lead to some problems, and the bigger one is that Mozilla employees won't be able to compile binaries for platforms with smaller userbases, such as IBM's PPC64el and S390X, deployed at various companies around the world.

 

The reason is that there's no Rust compiler for those platforms, which means that Firefox devs will fail when trying to compile a binary. The only way to fix this is if a compiler will be developed for those platforms.

 

Most Firefox users won't be affected by this change, but Mozilla hopes they'll see a boost in performance in the future.

 

In the upcoming year, Mozilla plans to replace most of Firefox's core engine, called Gecko, with Rust components. This operation will be done through small changes across different versions. Developer Jen Simmons perfectly described this very complex process in a blog post called "Replacing the Jet Engine While Still Flying."

 

Source

Link to comment
Share on other sites


  • Views 866
  • Created
  • Last Reply

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...