JavaScript has, over these past 25 years in existence, spawned numerous open-source engines and frameworks by third parties. Among the most recognized ones comes from none other than Google, whose V8 engine is the foundation to what powers billions of Chromium-based web browsers. As a high-speed development engine, it’s gone through evolutionary growth since 2008.

Now, V8 JavaScript performance running on Google Chrome or Chromium-based browsers will only get faster from here. It’s thanks in no small part to Sparkplug, their new compiler tool. It’s designed to be an ultra-fast non-optimizing compiler, sitting alongside Google V8’s other processes within the compiler pipeline. More specifically, between the Ignition Interpreter and TurboFan compiler.

What Does It Do?

What performance gains you’ll see will be most noticeable for short-lived operations. For instance, loading in a website, or popping open command-line tools. A core part of its design is that it doesn’t compile from a JavaScript source. Rather, Sparkplug compiles functions that have already once been compiled by the bytecode. There, most of the work has already been done by the bytecodes.

Moreover, Sparkplug doesn’t generate any intermediate representation, like most other compilers. In effect, this allows it to compile directly to the machine code in a single, linear pass. What you get is a highly lean and speedy little compiler. The Sparkplug compiler will make its debut soon in the V8 9.1 update, which will likely feature alongside Google Chrome 91. So, do keep an eye out.

Whilst debugging Javascript code sometimes support will ask for screenshots, on a windows machine it can be fairly straightforward. Screenshotting on a Mac can be more complicated. See the linked guide for more information.