---
title: "Optimizing WebKit & Safari for Speedometer 3.0"
description: "WebKit's Speedometer 3.0 work spans JavaScriptCore, DOM, style, layout, rendering and Safari itself, with measured gains for each change."
url: "https://swe.quest/articles/optimizing-webkit-safari-for-speedometer-3-0-a9a8d1c62cb906f4"
canonical: "https://webkit.org/blog/15249/optimizing-webkit-safari-for-speedometer-3-0/"
source: "WebKit"
published: "2024-04-10"
difficulty: "hard"
kind: "Deep dive"
reading_minutes: 11
tags: ["browsers","web-performance","runtimes","memory-management","performance"]
---

# Optimizing WebKit & Safari for Speedometer 3.0

A post on [WebKit](https://swe.quest/sources/webkit.md), published 2024-04-10, 11 min read, Deep dive. Original: [https://webkit.org/blog/15249/optimizing-webkit-safari-for-speedometer-3-0/](https://webkit.org/blog/15249/optimizing-webkit-safari-for-speedometer-3-0/)

## Summary

WebKit's Speedometer 3.0 work spans JavaScriptCore, DOM, style, layout, rendering and Safari itself, with measured gains for each change. The largest wins came from letting the simple text path handle font-variant-caps (4.5x on Editor-TipTap, ~7% overall) and from scheduling incremental sweeping and garbage collection opportunistically between rendering updates (6.5% on Speedometer 3.0). Other changes include reworked megamorphic and call inline caches, retuned inlining heuristics, lazy JIT code destruction, enum-based RenderObject type checks, cached CSS custom property resolution, and a larger IOSurface cache (hit rate ~30% to ~80%). Profile-guided optimization interacts with code changes in a surprising way: some improvements only appear, or briefly regress, until the PGO profiles refresh.

Written by swe.quest, not by the author.

**Difficulty:** Hard: written for specialists in the field

## Topics

- [Browsers](https://swe.quest/tags/browsers.md) (Web & mobile)
- [Web performance](https://swe.quest/tags/web-performance.md) (Web & mobile)
- [Runtimes & VMs](https://swe.quest/tags/runtimes.md) (Compilers & runtimes)
- [Memory management](https://swe.quest/tags/memory-management.md) (Compilers & runtimes)
- [Performance engineering](https://swe.quest/tags/performance.md) (Reliability & operations)

## Prerequisites

- JIT compilation tiers ([easy posts on Compilers](https://swe.quest/tags/compilers.md?difficulty=easy))
- inline caching ([easy posts on Caching](https://swe.quest/tags/caching.md?difficulty=easy))
- garbage collection ([easy posts on Memory management](https://swe.quest/tags/memory-management.md?difficulty=easy))
- browser rendering pipeline

## Keywords

WebKit, Safari, Speedometer 3.0, JavaScriptCore, CoreText, IOSurface, profile-guided optimization

## Related posts

- [Speedometer 2.1](https://swe.quest/articles/speedometer-2-1-0754b057a0ec4b71.md): WebKit · 2022-08-02 · Medium · 1 min read · Browsers, Performance engineering, JavaScript
  Speedometer 2.1 is a minor update that fixes the benchmark harness so it no longer measures artificial timer throttling.
- [Speedometer 3.0: The Best Way Yet to Measure Browser Performance](https://swe.quest/articles/speedometer-3-0-the-best-way-yet-to-measure-browser-performance-2c6a7e3e4a16f5e5.md): WebKit · 2024-03-11 · Medium · 7 min read · Browsers, Performance engineering, Web performance, Frontend
  Speedometer 3.0, jointly governed by Blink, Gecko and WebKit developers, changes how browser responsiveness is measured.
- [Release Notes for Safari Technology Preview 253](https://swe.quest/articles/release-notes-for-safari-technology-preview-253-dbd4fbc72270f33d.md): WebKit · 2026-09-23 · Medium · 16 min read · Browsers, CSS, JavaScript, Runtimes & VMs
  Safari Technology Preview 253 ships WebKit changes 320113@main through 321067@main for macOS Golden Gate and Tahoe.
- [New WebKit Features in Safari 14.1](https://swe.quest/articles/new-webkit-features-in-safari-14-1-a2719993e42ca6f7.md): WebKit · 2021-04-29 · Medium · 7 min read · Browsers, CSS, JavaScript, WebAssembly, Frontend
  Safari 14.1 (macOS Big Sur, iOS/iPadOS 14.5) ships Flexbox gap, macOS date/time inputs, CSS individual transform properties, the Paint Timing API, Siri-backed Web Speech recognition, an unprefixed Web Audio API with Audio Worklets, MediaRecorder, and WebM (VP8/VP9/Vorbis) playback on macOS.
- [WebKit Features in Safari 17.5](https://swe.quest/articles/webkit-features-in-safari-17-5-db83d5ba970a4034.md): WebKit · 2024-05-13 · Medium · 9 min read · CSS, Browsers, Frontend
  Safari 17.5 ships seven features and 22 bug fixes, led by CSS additions: text-wrap: balance (with the text-wrap-style longhand), the light-dark() color function, @starting-style for entry transitions, and supports() conditions on @import rules.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
