You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit d1ae801
Browse filesBrowse the repository at this point in the historyBrowse files
refactor(ios): one CGRect-to-SnapshotRect conversion; ADR names the real reason the frontier went
Review follow-ups on #2669.
- Every CGRect becomes a SnapshotRect through SnapshotRect.init(_:). The runner's snapshotRect(from:)
and the package's private SnapshotPresentationInvariant.snapshotRect(from:) were field-for-field
copies; both are deleted and their nine call sites use the initializer.
- ADR 0004 attributes the frontier removal to its cause: a post-walk normalization pass cannot feed a
decision the walk already took, so the fold-consulting frontier had to go; the mis-cut keyboard
band was the symptom. The measured cost of dropping it (form, catalog: p50 within 4 %, p95 within
10 % of main, in the branch's favour) is recorded there.
- CHANGELOG line for the presentation-cut route and the capability rename.
Copy file name to clipboardExpand all lines: docs/adr/0004-ios-snapshot-backend-strategy.md
+9-6Lines changed: 9 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -310,12 +310,15 @@ node at reported traversal depth and the frame the platform reported. #2661 also
310
310
coordinate space (`geometrySpace` / `parentIsWindow`) that #2612 had threaded through every walker;
311
311
the one coordinate-space decision is now a single post-acquisition pass over the flat array
312
312
(`SnapshotGeometrySpace.normalized`, run in `captureWithBackend`) that keys on ancestry instead of a
313
-
value carried down the stack. An earlier visible-depth frontier consulted the shared fold mid-walk, so
314
-
its presented-depth increment was measured against un-normalized geometry: a turned keyboard band
315
-
reported in the device's native space could be cut at the wrong presented depth before the single pass
316
-
ever ran. Dropping it means no reported rect can prune a subtree the fold would keep. The visibility
317
-
fold and the presented-depth cut both happen inside `SnapshotPresentation`, on the normalized array,
318
-
at `maximumDepth`. De-duplication drops a repeated node and re-parents its children onto that node's
313
+
value carried down the stack. That pass is why the earlier visible-depth frontier had to go: the
314
+
frontier consulted the shared fold mid-walk, and a post-walk normalization pass cannot feed a decision
315
+
the walk has already taken — the fold would read reported geometry, and a turned keyboard band in the
316
+
device's native space could be cut at the wrong presented depth before the pass ever ran. With the
317
+
frontier gone, no acquisition-time decision reads geometry, the walk is bounded only by raw traversal
318
+
depth and the node cap, and the visibility fold and the presented-depth cut both happen inside
319
+
`SnapshotPresentation`, on the normalized array, at `maximumDepth`. Measured on the recursive tier
320
+
(form, catalog; 7 warm captures each) the frontier bought nothing: acquisition p50 within 4 % and p95
321
+
within 10 % of `main`, in the branch's favour, with identical presented trees. De-duplication drops a repeated node and re-parents its children onto that node's
319
322
own parent, so identical rows collapse under one addressable owner instead of splitting a subtree
320
323
across two nodes with the same identity. Scoped captures remain broad because depth is relative to the
0 commit comments