From e3d807abc2dadc407be69d7dc022359e6ec9266b Mon Sep 17 00:00:00 2001 From: arzafran Date: Wed, 5 Aug 2026 10:06:02 -0300 Subject: [PATCH] Reland "perf(render): stop generating frames for occluded surfaces" MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Reverts the revert (60c14d6077). The teardown race the original bump exposed is fixed on main (#254): GhosttySurfaceCallbackContext is now data-only, so ghostty's IO-thread callbacks can no longer corrupt refcount side tables during rapid window teardown — the mechanism behind both CI crash signatures. The renderer patch itself is unchanged (fork commit c25020f99, prebuilt + checksum already published). Merge gate for this PR: CI must pass 3 consecutive runs on this head — the original failure was probabilistic and a single green proved nothing last time. The always-occluded CI environment plus this patch is the exact combination that crashed before, making this PR the definitive regression test for #254. --- docs/ghostty-fork.md | 18 ++++-------------- ghostty | 2 +- 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/docs/ghostty-fork.md b/docs/ghostty-fork.md index 155d21f9..294720d2 100644 --- a/docs/ghostty-fork.md +++ b/docs/ghostty-fork.md @@ -13,20 +13,10 @@ When we change the fork, update this document and the parent submodule SHA. ## Current fork changes Fork rebased onto upstream `main` at `3509ccf78` (`v1.3.1-457-g3509ccf78`) on March 30, 2026. -Current Programa pinned fork head: `b64213c5a` (surface revival path). - -The section 8 occluded-render skip (`c25020f99`, branch -`perf/occluded-update-frame-skip`, retain-ancestry merge `363d56e5d` on fork -`main`) was pinned on August 4, 2026 and REVERTED the same day: on CI's -virtual display every surface is permanently occluded, and skipping -updateFrame there removed incidental render-thread serialization that had -masked a pre-existing Swift-side window-teardown race (refcount side-table -corruption — "Object was retained too many times" / weak-reference-table -crashes in AppDelegateShortcutRoutingTests' rapid window create/close tests). -Re-land only after that race is fixed at the source in the app's -surface/window teardown; do not band-aid by re-adding renderer throttling. -The prebuilt release and checksum pin for `c25020f99` remain valid for the -re-land. +Current Programa pinned fork head: `c25020f99` (occluded-render skip, August 4, 2026), +reachable on the fork via branch `perf/occluded-update-frame-skip` and via the +retain-ancestry merge `363d56e5d` on fork `main` +(`Retain occluded-render pin ancestry on main`, the `5c781d710` convention). ### 1) macOS display link restart on display changes diff --git a/ghostty b/ghostty index b64213c5..c25020f9 160000 --- a/ghostty +++ b/ghostty @@ -1 +1 @@ -Subproject commit b64213c5af084c63ccad8016e5daa11ef217d79b +Subproject commit c25020f993597285a331a76dcd7c8a6345b7e360