Fnrr2oh.putty PDocsWeb Development
Related
Browser-Based Light Pollution Simulator: Real Photometric Data Drives Accurate Skyglow Analysis5 Key Improvements That Doubled JSON.stringify's Performance in V8Decoding Reality: A Step-by-Step Guide to the Boltzmann Brain ParadoxBoosting Copilot Studio's Speed: The Move to .NET 10 on WebAssembly10 CSS Pricing Magic Tricks You Can Use Without JavaScript10 Key Optimizations That Doubled JSON.stringify Speed in V8How to Use CSS contrast-color() for Accessible Text Contrast10 Insights into the Web's Structure Problem and How the Block Protocol Offers a Solution

Chrome 136 Ships 'Explicit Compile Hints' to Slash JavaScript Startup Bottlenecks

Last updated: 2026-05-06 01:58:01 · Web Development

BREAKING — Google has released Chrome 136 with a new feature called Explicit Compile Hints, allowing web developers to mark entire JavaScript files for eager compilation. The update aims to cut parsing and compile times by an average of 630 ms on popular sites, dramatically speeding up page loads.

“Getting JavaScript running fast is key for a responsive web app,” said a V8 team spokesperson in a prepared statement. “Even with V8’s advanced optimizations, parsing and compiling critical JavaScript during startup can still create performance bottlenecks.”

Background

V8’s default behavior is to defer compilation of most functions until they are actually called. While this saves memory during initial load, it forces the browser to stop and compile on the main thread when a deferred function is invoked — a costly pause.

Chrome 136 Ships 'Explicit Compile Hints' to Slash JavaScript Startup Bottlenecks

“If a JavaScript function ends up being called during page load, compiling it eagerly is beneficial,” explained a V8 engineer. “Doing the lightweight parsing first and the actual parsing afterwards is duplicate work.”

Eager compilation can be parallelized with network loading because it runs on a background thread. Deferred compilation cannot — it stalls the main thread until the function is ready.

In an internal experiment with 20 popular web pages, 17 saw measurable improvements. The average reduction in foreground parse and compile time was 630 ms, a significant win for user experience.

What This Means

With Explicit Compile Hints, developers can now insert a magic comment //# allFunctionsCalledOnLoad at the top of a JavaScript file to tell V8 to compile all functions in that file eagerly. The feature is especially useful for “core files” — scripts that run early and are crucial for rendering.

However, the V8 team warns against overuse. “This feature should be used sparingly though — compiling too much will consume time and memory!” They recommend focusing on files that are known to be called during the initial page load.

Early adopter feedback suggests the feature works best when code is organized into a small set of startup-critical files. Developers can also move code between source files to create a core file specifically for eager compilation.

How to Test

Developers can observe compile hints in action by running Chrome with a clean user data directory (to avoid interference from code caching) and logging V8 function events. A minimal test setup includes two script files: one without the hint and one with //# allFunctionsCalledOnLoad.

Chrome 136 is available now. For full implementation details, see the original V8 blog post.