summaryrefslogtreecommitdiff
path: root/src/tui
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-11-17 23:28:13 -0300
committerGabriel Schneider <[email protected]>2026-11-17 23:42:48 -0300
commit9b20d00ca5ffbab640b87249d65e4165414d22c1 (patch)
treee62644195d40b5a41ed92a5e19548fa84cff4821 /src/tui
parent6c61169832d6f396ee7a6e9e0b09d9c055d08f8d (diff)
downloadpardes-9b20d00ca5ffbab640b87249d65e4165414d22c1.tar.gz
pardes-9b20d00ca5ffbab640b87249d65e4165414d22c1.zip
replica: a record of a MiB or more crosses to a client by its hash, beside its unit (tape.zig by_hash_min, Big; wire blob): a file over the wire's 16 MiB bound opened while a client was attached was one unit, past the bound, so a Debug session panicked and a release one dropped it, its client diverging at the next unit and joining again to be sent the whole file in the dump; now the read's answer is recorded as the file's BLAKE3, a client on the session's machine reads the path itself and checks it, a far one is sent it in 1 MiB pieces before the unit and keeps it in its cache.xitdb (XDG_CACHE_HOME/pardes), so a far client that joins after is sent none of it; any other record that long (a reload's text, a paste) goes to every client so; test/daemon.py by_hash: a 17 MiB file under a near and a far client, both agree, neither joins again, the near one reads it itself, the far one is sent 8848 KB of zstd and a far client after it none of its 2 blobs; the slot's own BLAKE3 the brief asked for was built and taken out (a hash a kind's open, 7 instructions a byte on the perf build's CPU, for no reader until a client renders kinds); perf --only medium --reps 10 instructions:u 2,459.25M -> 2,459.36M, --terminal-mib 8 3,928.50M -> 3,928.51M; tui core-test 811/950 (139 skipped), shell-test passes, replicas pass (diverged 0, checked/wrong 0), behaviour-test 269/273 (the four addon ABI tests the base fails), --replay 20 seeds 0 failures, process-test 2 of 144 failed (lspcomplete and lspcompletemoved, the base's; headersweep and headersweep-restored failed once at load 14 and pass alone), test/daemon.py passes
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'src/tui')
-rw-r--r--src/tui/tui.zig4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/tui/tui.zig b/src/tui/tui.zig
index 349ced56..919eeded 100644
--- a/src/tui/tui.zig
+++ b/src/tui/tui.zig
@@ -805,7 +805,7 @@ pub fn runClient(init: std.process.Init, opts: pardes.Options, path: []const u8,
const ended = reader_done.load(.acquire);
while (loop.tryEvent() catch null) |ev| switch (ev) {
.said => |said| switch (said) {
- .unit, .screen, .refused => |b| std.heap.c_allocator.free(b),
+ .unit, .screen, .refused, .blob => |b| std.heap.c_allocator.free(b),
.checked => {},
},
.paste => |b| gpa.free(@constCast(b)),
@@ -1732,7 +1732,7 @@ const Shell = struct {
c.link.take(said);
if (said == .refused) return true;
} else switch (said) {
- .unit, .screen, .refused => |b| std.heap.c_allocator.free(b),
+ .unit, .screen, .refused, .blob => |b| std.heap.c_allocator.free(b),
.checked => {},
},
.link_gone => if (s.client) |c| {