diff options
| author | Gabriel Schneider <[email protected]> | 2026-11-21 17:31:25 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-11-21 19:27:50 -0300 |
| commit | 71a68eac9d4bce7deb19236a9cc8338b1a37caa1 (patch) | |
| tree | 9c667f806046f528cc295ef397a954ae67ced107 /core/Core.zig | |
| parent | 2b9da7be7d9520701b24d46d8db2ec56517b45b8 (diff) | |
| download | pardes-71a68eac9d4bce7deb19236a9cc8338b1a37caa1.tar.gz pardes-71a68eac9d4bce7deb19236a9cc8338b1a37caa1.zip | |
layers: with `Changes` off a client's key pays for items A and B no more: all of jj's session state is one field, `Pardes.changes: jj.Session` (jj's answers by pane serial, the `Changes` jj runs for, the one asked meanwhile, how many were asked), whose digest is nothing until a `Changes` is asked and then one update while nothing is asked of jj, where item A had three `Stream` fields (three updates in every digest of the session, and a client's key takes several digests) beside round 4's answers list (one more); `Stream` holds nothing of jj's again (its dispatch lines stay), the session's end lets the worker and the asks go in `Session.deinit`, and the batch's 8-byte `jj` field goes (a `Changes` answer is told by its generation's bit, `jj.gen_bit`, after a paint's, and the pane it is for is the ask's, which every replica holds); measured first, a variant at a time, client-key-down against tree3's pardes-perf in the gate's own layout (ReleaseFast gui, its farms and HOME; my first script's layout read about 0.05% lower): item B as it was small +0.111%, the batch's field gone and the stream's three fields one +0.104%, the session's state one field digested as nothing until asked small +0.047%, large +0.047%, medium +0.010%
Co-Authored-By: Claude Opus <[email protected]>
Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'core/Core.zig')
| -rw-r--r-- | core/Core.zig | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/core/Core.zig b/core/Core.zig index 177a6e78..efa2ac3d 100644 --- a/core/Core.zig +++ b/core/Core.zig @@ -355,10 +355,11 @@ lsp_ask: Ask = .{}, pipe: Pipe = .{}, /// A query pane's Grep, and its Find's listing, on a worker (Stream.zig). stream: Stream = .{}, -/// What jj answered for each pane's `Changes` (jj.zig), by its serial: the -/// session's list, not a field of every pane (a digest and a rollback copy -/// walk every pane's fields at every step). -changes: std.ArrayList(@import("jj.zig").Changes) = .empty, +/// The panes' `Changes` (jj.zig): what was asked of jj, and what it +/// answered for each pane, by its serial: the session's, not a field of +/// every pane (a digest and a rollback copy walk every pane's fields at +/// every step), and nothing in a digest until a `Changes` is asked. +changes: @import("jj.zig").Session = .{}, fs: filesystem.Namespace = .{}, boot: Boot = .shell, @@ -868,7 +869,6 @@ pub fn deinit(p: *Pardes) void { for (p.spawn_dirs) |d| if (d) |dir| gpa.free(dir); p.pipe.deinit(gpa); p.stream.deinit(gpa); - for (p.changes.items) |*c| c.deinit(gpa); p.changes.deinit(gpa); p.handover.deinit(gpa); if (p.stream.ahead.len > 0) p.tree_sitter_gpa.free(p.stream.ahead); |
