AH Chrome

TurboFan To Replace Chromes Previous Compiler

July 9, 2015 - Written By Juan Vega

Google has been working on a new JavaScript optimizing compiler for its Chrome Browser to replace its current offering, Crankshaft. Aptly named TurboFan, the new compiler offers a plethora of new features that make it a much better tool for optimizing JavaScript. Chrome team member Ben Tizer states, “It optimizes more code than the previous optimizing compiler, supports flexible and dynamic optimization modes, and enables easier contributions and maintenance.” Quite a list of features for a compiler that has only been in development since 2014.

Announced back in December of 2010, Crankshaft was a great milestone to Chrome’s V8 engine. With speed improvements reaching 2x in some instances and apps loading up to 12% faster in others, Crankshaft helped propel Google’s browser ahead of its competitors in record time. Google was able to achieve these results by making the compiler only optimize code that was run frequently instead of making it use resources to optimize all code. No need in making the compiler run in all scenarios of using the browser if you only found yourself using the same features all the time, which would mean that the same code would be run each and every time. This reduced the workload on the browser which in turn made it run faster and smoother. That was 5 years ago however and if Google Chrome wanted to continue to stay ahead of the competition, it was going to have to continue to innovate and makes its browser faster and better.

That’s where TurboFan comes in though it’s not quite ready to enter the arena just yet. There are still some kinks that need to be worked out for it to be a viable replacement for the current and aging compiler. For now TurboFan is only executed in certain instances of JavaScript that Google has determined perform faster compared to using Crankshaft. The search mogul plans to continue to improve the compiler to make it run in more instances and situations. The end game is for TurboFan to take over from Crankshaft, but it may still be a while before that occurs. TurboFan offers great improvements over Crankshaft and will surely be hit once it reaches the official versions of Google Chrome.