Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
marjakh authored Apr 3, 2024
1 parent 4d61e3d commit c50f483
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ If a JavaScript function ends up being called during page load, doing the parsin

Based on initial experiments, Google Docs report 5-7% improvement in their userland page load metrics with our prototype implementation, when selecting the core JS file for eager compilation.

Currently, Chromium and Firefox use the [PIFE heuristic](https://v8.dev/blog/preparser#pife) to direct which functions to compile. This heuristic has existed for a long time and is well known to web developers. Safari doesn't follow the heuristic.
Currently, Chromium and Firefox use the [PIFE heuristic](https://v8.dev/blog/preparser#pife) to direct which functions to compile. This heuristic has existed for a long time and is well known to web developers - some web pages (e.g., Facebook) use it or have used it for triggering eager compilation. Safari doesn't follow the heuristic.

Using PIFEs for transmitting information about which functions should be eager-compiled has downsides, though. Especially:
Using PIFEs for triggering eager compilation has downsides, though. Especially:
- using it forces using function expressions instead of function declarations. The semantics of function expressions mandate doing the assignment, so they're generally less performant than function declarations. For browsers which don't follow the PIFE hint there's no upside
- it cannot be applied to ES6 class methods

Expand Down

0 comments on commit c50f483

Please sign in to comment.