diff options
| author | Gabriel Schneider <[email protected]> | 2026-11-21 14:17:28 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-11-21 14:58:57 -0300 |
| commit | 8152cf383c8296be29e80175b57e40f8d41049bf (patch) | |
| tree | 98ab59c0122b73ca6490ab4b778bf0fb7f0582d0 /core/panes.zig | |
| parent | dfb051bd798f65c2217eea7f95b03dce292e30bf (diff) | |
| download | pardes-8152cf383c8296be29e80175b57e40f8d41049bf.tar.gz pardes-8152cf383c8296be29e80175b57e40f8d41049bf.zip | |
layers: with `Changes` off nothing is paid (P45): the revset and jj's answers are the session's, a list by pane serial (`Pardes.changes`, `jj.answered`; `jj.forget` at the pane's end), no longer a field of every pane, and a view holds only whether it shows them (`File.Layers.lanes`, the cells their lanes take, hashed with `ink` in one update), so a second view's `Changes other` shows the new set in both and its bare `Changes` hides them in its own alone (bare with none pinned yet is `@`); measured first, per operation against gpu/tree3 (a gui ReleaseFast pardes-perf, perfops's way of counting: reorg/pardes-layers-4/perf): merge50 +0.005% a client key, round 3 +0.110%, a packed one-byte `Layers` +0.391% (a packed field cost the walks more), a plain two-byte one +0.152%, the per-pane field gone +0.118%, the gutter's three reads of the lanes taken out +0.066% with body-appends from +0.189% to -0.004%: what paid was fillBody's line number, formatted for every row of every geometry pass (no `dst`, a hundred a frame) and thrown away, whose row loop moved with any value added to it: it is now written only into a `dst` (client key +0.017%, deep-sel +0.002%, render -0.021%, body-appends -1.555%); and `jj.of` (round 1's) gave a revision's name as a slice of a by-value copy of the pane's Output, dangling once it returned (jj told "Non-UTF-8 argument" for `Changes` in a revision's pane in a window build): the pane's own now; tests: the pinned changes are the pane's, shown in a view by its own bit (a second view's revset shows in both, its bare Changes hides them there alone), the two of a terminal's cells said so (`.windowed = false`); core-test 896/1056 (160 skipped), shell-test 1098/1101 (3 skipped), gui unit-test 1695/1699 (4 skipped); the frame and perf gate against tree3 (gpu/l4-g0): 77/77 frames, 0 differ, perfab corpus2x +0.005% (noise 0.058%), perfops 121 counts within 0.1% (largest terminal on all +0.082%)
Co-Authored-By: Claude Opus <[email protected]>
Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'core/panes.zig')
| -rw-r--r-- | core/panes.zig | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/core/panes.zig b/core/panes.zig index ee03ccf2..8b152132 100644 --- a/core/panes.zig +++ b/core/panes.zig @@ -320,9 +320,6 @@ pub const Pane = struct { view: SessionView = .{}, /// The painters a file's body wears in this view (File.Layers). layers: File.Layers = .{}, - /// What jj answered for the last `Changes` in any view (jj.zig): the - /// pane's, so a client that joins late has it in the dump. - changes: ?*@import("jj.zig").Changes = null, sel: [3]Sel = @splat(.{}), pointer_selections: [3]?PointerSelection = @splat(null), next_pointer_selection: u64 = 0, @@ -1282,11 +1279,7 @@ pub fn teardownPane(p: *Pardes, pane: *Pane) void { pane.input.deinit(p.gpa); pane.jump.deinit(p.gpa); pane.places.deinit(p.gpa); - if (pane.changes) |changes| { - changes.deinit(p.gpa); - p.gpa.destroy(changes); - pane.changes = null; - } + @import("jj.zig").forget(p, pane.serial); if (pane.query) |q| { q.deinit(p.gpa); p.gpa.destroy(q); |
