TurboFan For Enhanced JavaScript Performance
Written by Alex Armstrong   
Thursday, 16 July 2015

TurboFan is Google's latest new optimizing, just-in-time, compiler for speeding up JavaScript execution  in Chrome.

It first appeared in Chromium almost a year ago and it has been shipping as a component of the V8 JavaScript engine since Chrome 41. 

As Ben Tizer explained in a blog post TurboFan outperforms Crankshaft and copes better with:

 some types of code that were challenging for our previous compiler to optimize, such as asm.js, class literals, with scopes, computed property names and for-of loops.

In a more technical blog post Tizer explains:

"The TurboFan JIT implements more aggressive optimizations than CrankShaft through a number of advanced techniques. JavaScript enters the compiler pipeline in a mostly unoptimized form and is translated and optimized to progressively lower forms until machine code is generated. The centerpiece of the design is a more relaxed sea-of-nodes internal representation (IR) of the code which allows more effective reordering and optimization."

 

turbo

"An optimization engine applies these local rules in a systematic and thorough way. Transitioning out of the graphical representation involves an innovative scheduling algorithm that makes use of the reordering freedom to move code out of loops and into less frequently executed paths. Finally, architecture-specific optimizations like complex instruction selection exploit features of each target platform for the best quality code."

Having turned it on selectively Google has already seen some positive results, including a 29 per cent increase in the zlib compression score of its Octane benchmark suite.

 

tfaninc

 

Tizer concludes his post saying:

Over the coming months, we expect to enable TurboFan for more and more types of JavaScript, with the eventual goal of entirely replacing our existing CrankShaft compiler. As it rolls out, developers' code will automatically get these free speedups with no changes needed. Stay tuned for future progress. 

 

chromedevs

  

Banner


Ursina - A Game Engine Powered by Python
08/11/2024

Ursina is a new open source game engine in which you can code any type of game in Python, be it 2-D, 3-D, an application, a visualization, you name it.



Go At Highest Rank Ever in TIOBE Index
20/11/2024

Go is currently in 7th place in the TIOBE Index for November 2024. Not only is this is the highest position it has ever had, it's percentage rating is almost equal to its all-time-high. Will Go contin [ ... ]


More News

 

espbook

 

Comments




or email your comment to: comments@i-programmer.info

Last Updated ( Thursday, 16 July 2015 )