| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
|
|
| |
Keep tracking after each history jump, use a shorter threshold for subsequent steps, and allow reversals without lifting. Stationary fingers and post-gesture momentum do not repeat commands.
Remove preview haptic pulses so feedback accompanies navigation only. Update the guide and adapter regressions for repeated steps, reversals, cancellation, threshold reset and absence of preview pulses.
Validated with the native adapter tests, macOS GUI release build, remote session rendering and digest checks, and user trackpad testing.
|
| |
|
|
|
|
|
|
| |
Add a thin AppKit input adapter for SDL trackpad momentum, multi-finger and force clicks, deliberate pinch zoom, rotation haptics, and shorter history swipes with early haptic cues.
Keep remote cursor motion on the frontend clock, resolve configured fonts locally, follow terminal directories without an authority window, and render live tagline themes without waiting for daemon ticks.
Validate with native GUI and TUI release builds, trackpad policy and adapter tests, targeted scroll and replica theme regressions, live remote digest checks, visual theme switching, and user trackpad testing.
|
| | |
|
| |
|
|
|
|
| |
session lives is asked again (three times), and the harness goes on (a 20-minute box run ended at 14 min on one `kill -0` over ssh that took more than 30 s)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
daemon.py's made_live: the first may answer a check the client took before it sent the key, and its /layout read another client's view, still the live one (the "panes left its view with no rejoin" breaches, at 207 ms: a line 104 and 133 ms after the key, where one asked after it comes no sooner than ~500 ms)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
so a build's words, the rows of its Help, are the same on FreeBSD: a Linux client of a box session made SPC ?'s +Help with one row more than its session's and joined again (`pane 4.file.content`, and `.splice` over a +Help made again: two of the box soak's three divergences); whether its host is Linux is the authority's answer (tape.authority), so a replica of a FreeBSD session refuses Tty9p as its session does; test/cross_replay.py's session runs Help (a FreeBSD tape replayed here diverged at its pane's content)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
the panes opened in it: an Upgrade's clients and one whose bye says it joins again (a divergence's, wire 19's `bye.again`) leave their view kept for them (`views_away`, digested and dumped, so an Upgrade's new build has it; taped `awayView`), the client names it in its next hello (`Hello.view`, handed on by the daemon with the connection) and its join takes it back (taped `rejoinView`) rather than a copy of the session's; the live view is never a kept one, `views.count` counts the others, and a join with every view taken lets one go (every Upgrade made each client's own panes leave its view: the hunt's 80 ms cell lost `+Search` and `+New`)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
(left open, it took the next action's keys, and a `k` at a column's top went to its tag, where `quebec` typed `SPC q`, Exit, and a session with nothing unsaved quit as asked: the box's 1093rd-input quit), and no word starts with q
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
client's guess of the session's clocks (wire 18's `stamp`), the guess its speculation records, and the authority's step reads that, not its own clocks (within a second of them, else its own), so a step's clock read never mispredicts: an edit's second across a turn, a message's millisecond (Ctrl-W's, a jump's) were each a rollback (fixer 1: 4 seen in 2 minutes), and every reapply of one now reads the same time
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
their like: the monkey's keys land in tags, and minutes of them ran Exit there (the box's session quit cleanly 88 s in, its stats written, no panic)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
joined again since (its view new, the known gap) or not, with its /index row; the check compares serials (/layout's and /index's), never slots
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
round trip too (a window's software present takes up to a frame); the shell's predicted echo counted over its letters, not the link's keys (its Ctrl-U is never predicted)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
(type in a file, at a shell prompt, move by keys and by click, scroll a file by keys and the wheel, a terminal's history by keys and the wheel, select, the Panes picker) and client kind, the share applied at once (the replica's trace of stopped inputs, and shown within half a round trip), keystroke to present p50/p99 against a local session's frontend measured in the same run, and the shell's predicted echo; breaches under 99% at once, over two frames past local, under 95% predicted; the soak's blink breach at a visible rollback a minute; clicks as one write; a box restart with no core to keep
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
client's rejoins after an Upgrade counted by the Upgrades made while it ran (its notice can be gone before a frame shows it); a client's visible rollbacks are its process's count, not summed over its links
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
client's speculation (at once of its inputs) and predicted echo in the table; each session's log kept an epoch, and a dead box session's core; the box's 9P forward waited for until it answers, its socket made afresh at a restart
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
again as its user would, and the session too, its epochs counted; the panes on a client's view kept between quiet points (lost: still open, no longer on it); rejoins after a divergence told from an Upgrade's; each client its own XDG_STATE_HOME, as a client on another machine has; cores (systemd-coredump) and deaths by signal are breaches; a session that will not Exit is killed, not a lost table
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
each link, measured: a session on a directory and two shells (here, or on the FreeBSD box over ssh), terminal clients in a pty kept by pyte and offscreen window clients through their test feed, each a seeded monkey of moves, edits, undo, saves, Looks, pickers, shells with programs, panes and columns, clicks, the wheel, the pointer resting, pastes and idle gaps, beside resizes, detaches and attaches, an Upgrade and a script's 9P edits; its table a client (rejoins, checks that differ, exits and cores, freezes at quiet points, a terminal client's screen and cursor against the session's render of its view, visible rollbacks, keystroke to output or frame p50/p99) and the session's worst boundary, exit 1 on any breach; test/delay_relay.py takes --jitter (order kept)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
step's unit, not inside it (resize_to, made by Peers.unit, null from `create` on): a client typing at another size than the last typist read history rows its replay held as holes, and the rows the session sent for them came in the new grid's numbering, which the replica cannot take, so its replay read blank text (the soak's local80 cell: jumps, njumps, jcur, pane 1.body at a b; fixer 2's H18, pane N.ovl); test/replicas.zig sizes them after its fill too; an in-process test reads the history in the step that resizes, with the session's order of flush, fill and unit, and another makes a terminal from 0xAA memory and finds no size waiting
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
whether it found anything) is a tape site, `search`, its batches what the replay takes, as it takes a worker's (Event.search): its file reads were no site, so a replica of a session a script greps in read no file and joined again (`a syscall that is no tape site, made replaying`, a terminal client live, 2 of 2 before, none after); test/cross_replay.py's session greps and finds again
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
| |
write's clunk is answered: that EOF is the session gone, as asked (exit_session, at the three places that Exit twice past unsaved text)
The far clients' teardown failed once in a Debug run of 20: the second Exit ended the session, and ninep.write's clunk after it met the closed link, an EOFError the test did not take for the session going. The session is right: a link is closed with its session, whatever was asked on it after the write that ended it. Four runs of 20 since, each through the far clients.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
its number: registry.Builtin, made at compile time, has Tty9p in a Linux build and not a FreeBSD one, so a +LocationsConfig (its output's origin a Builtin) digested otherwise in each, and a Linux client of a FreeBSD session holding one could not join (the hunt's H19: `the session's dump loaded as another session`, main's window client of main's session on the box; after, a terminal and a window client here join one with a +Search, a directory, a renamed file and a +LocationsConfig, and agree); walk's test, and test/cross_replay.py's session holds a +LocationsConfig and a renamed file (a FreeBSD tape replayed here diverged at pane 2.file.output before)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
its wait, not in the host's wait: the host's call (tty waitInput, gui waitDetached) was no input, its clock read untaped, so a replay (and every replica of a session nobody attached) kept a message its session had let go; with MessageLinger 0 (test/daemon.py's sessions) a tape whose session said a failure never replayed, on main too (pane 0's msg, digest 6, 7 of 7 runs; 0 of 6 after); test/cross_replay.py's session says MessageLinger 0 again
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
(Layer.Place, on the wire, version 17) and a step resolves it from that, never from this process's frame (`surface`, `.local`), which a session never draws for a client: a window's pointer over a tag diverged it at once (the user's `tape byte 119`, 15 rejoins in 25 s) and a click there aborted it; a replay that meets a site its tape lacks, or makes a syscall that is none, is a divergence that goes on harmless (poisonOf), not a panic, and a speculation that makes one waits (Tty's shell lookup, untaped, is a value site now, as Shell's was); a copy over a queue is refused, not asserted; a session's last client, while no one else watches it, leaves it its layout (leaveView, settled as closeView is), which its rejoin copies; a redial waits only after an Upgrade's `refused` (a divergence's redialled a gone session 20 s); a dying session shuts its clients' links before its trace, and an --attach client ends its ssh and socket whatever way it exits; a far join's hashing stops at a blob once its client is let go (its leave waits for it in the step); a confirmed speculation's state is checked against its unit's digest, and the trace gives a key's and a pointer's words; test/daemon.py: 200 far joins level, a window's pointer swept over tags and body, ssh stand-in clients refused and detached, a client of a killed session ending in 2 s; in-process tests for each
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
calls glibc's in a program linking libc, which writes its 60-byte termios into Zig's 44-byte one, 16 bytes past (main.zig exports kernel ones; this program has none)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
and Recent pickers and jump, now and then: the store's and Recent's rows, a closed pane's jumps, from replicas that rolled back over them
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
fifo and of a directory, a Save into a file, a Restore of no dump, a stat and a read under /os) recorded by one build of pardes and replayed by others, its errors by name in the tape; --record and --replay alone, for the box; pardes-snap --replay-with (zig build replay -Dreplay-with=<pardes-gui>) replays every script's tape with another build too, whose replica that draws nothing must agree (a replica client draws none of its session's frames)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
off as it lags said nothing and exited 0 when its own write found the link shut before its reader did); a window client's frame is marked rendered as it presents, so the live harness reads its render as its core's time; test/daemon.py's window clients: one far (PARDES_REPLICA_FAR) put off the session's state rejoins from the core it left, and again across an Upgrade (its `refused`); a client's echo stats in PARDES_REPLICA_STATS; --ps beside them lists the session alone, a window's as (gui, attached), its clients none
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
<host>:<name>, as the tty's, far through ssh as amort's: its blobs by hash and its stream in zstd) and a window session serving replicas (a terminal's client or a window's): the client feeds its replica what its window does, read over its own view (views.within) and applied after, draws its view between steps, takes the stream on its own reader and rejoins as the tty's does (replica.Link, the client's half shared with it, the far path's Have with it); the session takes clients at its step boundary, one person's input a wait, a client's view no window of its own, its font and opacity answers taped; a client says its frontend first (Event.frontend, in wire 16 beside the far word) and the tty and window builds step alike (one desktop semantics: each has the other's words, which a view takes by its own frontend, builtins.registry.here); a check asked 300 ms after the last input and check, not per wake; test/daemon.py --window-clients
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
tree (the daemon, each session with its pid, kind, state and name and the shells it holds, then the shells no session holds, which Adopt takes) and sessions ended with their shells: a TERM, a KILL 2 s later, gone once the daemon no longer lists them (a zombie still answers kill 0), a killed session's held masters closed rather than kept for an Adopt and --kill-all's every kept one; in --help, the guide and the reference; --help's ssh default no longer -C; test/daemon.py --manage
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
blobs by BLAKE3 hash first (wire 16 `blobs`), the client finds each in the core it leaves or on disk ($XDG_CACHE_HOME/pardes/blobs, hashed again on load, a bad file a miss, the least recently used evicted past 1 GiB) and asks for the rest (`want`), and everything after the welcome goes in zstd envelopes (level 6 over 8 MiB for the join, an undo snapshot being a near copy of its text, then level 3), so `ssh -C` leaves the default command; a far client (through ssh, or PARDES_REPLICA_FAR) keeps what it was sent and, at its end, what it made; a hangup ends a remote client the normal way; through the box a client holding the blobs is drawn in 2.4 s where main took 7.0 to 11.9, and a first join of a session with undo in 7.1 s where main took 11.9; libzstd 1.5.7 vendored, its allocations on c_heap, a second copy refused by shared-libs-check; tests for the cache's verify-on-load, its eviction and a far join's blobs sent once; test/daemon.py's far clients
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
closed under a blocked read stays open until the read returns, so the terminal never hung up and its stub waited; its fd's number, taken again, was read by the old thread); the stub's last words waited for rather than read at once; a client's next keys wait until its Esc has taken it out of insert mode (written behind the Esc, they came in one read with it as Alt on the first): the three that failed one run in ten or more under load
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
now streams before its pong
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
| |
session's own screen: the live view has no terminal here, and the attach returned without a word, its stub waiting and its terminal blank (the main test's third terminal, on the box)
test/daemon.py: the clients test attaches one while a client's view is live.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
did not end on) and one the session let go to upgrade dial it again, the same join as the first, and say why in a line over their frame until a key; a client of another build is told "session upgraded to a newer pardes: upgrade this client too"
tty.zig `remote` is a loop of joins over one terminal: the link ended, its reader joined, the replica let go, the session dialled again (an upgrade's exec and load, and its daemon's, retried for 20 s), its dump loaded, its view's size sent again. `Remote.notify` draws the line (`noticeLine`, the client's own, never the session's core).
The welcome carries the session's semantics: the daemon judged the hello by the hash it last heard, which an upgrade under way may not have said yet.
replica.zig `Peers.refuseAll`: before an Upgrade's dump each client is sent `refused` after what it was sent (up to 200 ms) and let go, its view with it.
"A newer pardes is installed" is a Host call (`newer_build`) the core makes in its focus step, so replica clients take the line from the tape; the GUI still says it itself.
PARDES_TEST_DIVERGE=<n> puts a client's core off the session's once quiet after its n-th unit. test/daemon.py: the clients test has one rejoin and agree; the upgrade test has a client of the old build told to upgrade and one of the build running join again and agree.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
unit after it (replica.zig `Peers`, a writer and a reader thread a client, units at each step boundary, a client's input stepped there in its own view), and `pardes --attach=<socket>:<name>` and `--attach=<host>:<name>` (through `ssh -tt -L`) are a client in the tty host, its keys applied at once by its own replica and drawn by its own process
wire.zig version 15: welcome (the client's id and view, the dump's length, the session's UTC offset and digest), dump pieces, units (with the authority's clocks), terminal messages both ways, a check. A unit carries one digest, at its end (`unit_digests`).
The client: tty.zig `Shell.remote`, `feed` (a terminal's input to the replica and the session); the session's clock guessed from the last unit's (tape.zig `Guess`); a pump woken only by a client's post reads no new time (`mail_only`), and a unit of another's ending where the last ended leaves the speculation as it is (`neutral`); the rollback copy taken while idle (`Replica.ready`); views a frontend here does not draw left undrawn.
A lagging client never holds the session: its queue is cut off past 64 MiB (PARDES_REPLICA_LAG_KB). Detach in a client ends that client; a Restore lets every client go.
daemon.zig: a replica the daemon hands over is the session's loop's (a note), not a stub thread's. A window session refuses one in words.
test/daemon.py `--clients`: two clients (one through the delay relay) type into a detached session and agree with it, one killed outright, one detached, a third typing into a shell.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
printable character at the cursor, Backspace, Left and Right, in tty mode on the primary screen), from an overlay of its own that no digest, dump or rollback copy sees, painted over the terminal's body at the end of renderBody (the tty's and the GUI's); judged at each delta once the authority has the key and 50 ms have passed, every prediction taken back on a mismatch; drawn at once at a prompt pardes's marks vouch for, elsewhere only once an echo was confirmed, never after a drawn misprediction until one is, so a password prompt or a program that ignores input shows nothing typed; the keys typed behind one not predicted (Tab, Enter) predicted over the screen that shows its doing; zig build replicas -- --echo types a corpus into a played shell at 30/80/207 ms: a key to its character p50 239 -> 8.9 ms and p90 248 -> 15.8 ms at 207, no wrong character drawn; docs/next-daemon.md: the decisions, the hook for the remote client, the numbers, the gates and what is not done
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
| |
detached one) ended by their private runtime directory, after each cell and in the cleanup every path takes
Since phase 3 a tty stub killed detaches its session rather than ending it, and an exe that wraps a session of its own (`--detach`, as the remote agent's client-live.sh starts one) leaves it when the harness kills the wrapper. Every process a live run starts inherits its private XDG_RUNTIME_DIR, which nothing else has: `liveSweep` sends TERM, then KILL, to each whose /proc environ names it, after every cell and in liveCleanup, which every path takes. With a wrapper that leaves a daemon-kept detached session, the old harness left three (one a cell) and their daemon; this one none.
perf.zig is the harness's identity, so the gate's baselines are recorded again from base (main and this perf.zig), each built on the build cores and run alone on the perf cores; their build identities are the old ones. .scratch/daemon/base/pardes-perf-live is rebuilt from it (ReleaseFast).
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
focus-in, once a build, the path read just after the first frame (off a startup's way); an upgraded process lets the binary it replaced go (held, its deleted file kept its blocks) and sweeps its old image's prompt files (kept for an exec that failed); test/daemon.py --upgrade asks through /ctl, checks the fds and prompt files level, and runs on FreeBSD (procstat, the daemon's registry, no kept old binary there)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
the pardes installed where it started, in place, by exec at a step boundary: its dump in the DumpDir, its pty masters, terminals, stubs and daemon link kept open and named on the new command line, every view and running shell its own again; the daemon re-execs too, its registry on its command line; a build that cannot load the dump falls back to the old binary, or starts afresh with the shells adopted and the dump kept (test/daemon.py --upgrade, --upgrade --gui)
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
keeps over it taped, the history a step reads sent before its unit, rows sent a blob once a message, and the rows cache out of the rollback copy
terminal.zig, tape.zig: ingestWithPositions tracks its rows only where an ingest happens; what the ingest told them (each tracked row's row after it and whether it was erased, a clear, whether the pages lived, a pin not made) is a taped value (Site.positions), which a screen-state replica, ingesting nothing, takes; the logic after it runs alike on both. On the stack, so the local path allocates nothing new. buildRows marks a terminal read (State.read) outside the render (terminal.drawing).
screen_state.zig, replica.zig: the authority keeps each peer's holes as its replica does (Peer.holes, from the deltas it sent), and Screens.fill sends a peer the rows it lacks of every terminal a step read, after the step and before its unit, so a replay reads what the step read (a text-mode cursor moved into history the flood scrolled past diverged). encodeRows sends each distinct blob once a message and the rows as addresses (a fill after yes is a third). The rows cache is dropped when a copy is taken and emptied when it is put back, not saved.
test/replicas.zig: Ctrl-b in the mix (a shell out of tty mode: text, cursors and selections over it), and a shell's session (prompts, titles, directories, clears) between the TUI and the flood. 4 seeds x 120 inputs x 3 clients at 30, 80, 207 ms: no divergence, every replica and terminal the authority's, 4,653 deltas checked.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
| |
trimmed by the thousand (a yes delta applies in 97 us, was 2.4 ms), holes blanked when they come into view, and input into a terminal left to the authority
screen_state.zig: when a delta's scroll is more than the replica's screen and history hold, nothing it holds is in the new state; its rows stay where they are, renumbered, the active ones and the tail written from the delta, the rest holes, and only as many more rows grown as the authority's history is longer. A hole has whatever that row held before, so `blank` clears the holes in view before they are asked for. The bench's floods run under the C allocator, as a replica does.
replica.zig: a replica's input whose live pane is a terminal is not speculated (its step reads the emulator, the last delta's here and the pty's newer one there): it waits for the authority, as a key in tty mode already did at its pty write. ReleaseFast, 200x60 yes at 16 MB/s: apply p50 97 us, p99 284 us; encode a frame 41 us at one peer and at three; 64 KB/s a peer.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
several in flight against the version last sent, its history the authority's to the row, and the authority's own steps batched into a unit a frame
screen_state.zig: each state the authority sends is a version of its terminal (Track), made once for every peer; a peer's delta is against the version it was last sent (the stream is ordered and loses nothing), up to 32 in flight, a peer at the bound waiting for an acknowledgement and then getting the newest; peers at one base are sent the same bytes. A replica refuses a delta against another base and is started afresh. It keeps the authority's history extent to the row (no byte limit of its own, trimmed to the authority's count), takes its viewport and its cursor's semantic content, and grows a flood's rows in bulk. The soak now keeps several in flight, lands them late in order, loses one now and then, and checks the history extent and the viewport too.
replica.zig: Screens (the authority's tracks and peers) and Replica.screen/screenRequest, messages of u8 pane, u32 serial, u8 kind (a delta, rows; an ack, a row request, a reset). Deltas are applied with the replica's epoch paused, so an emulator outlives a rollback. Authority.output/pending: its own steps (a pty's output) go into one unit, sent before any other input it steps and at a frame, with one digest; under screen state a digest is one word.
tape.zig, terminal.zig: under screen state an output is recorded without its bytes, pty writes are off the tape on both sides, no digest covers an emulator, and a replica's core never ingests or resizes one (a resize's own core work, the pointer selections cleared, still runs). A terminal counts its writes (State.changes); its MarkedHandler cycle rides in each delta.
test/replicas.zig: the session's shell runs a TUI, then 8 MB of yes read 4 KB at a time, while three clients type; deltas go out before each input the authority steps and once a frame, acknowledgements and row requests come back over the links, every applied delta is checked against the authority's screen at that version and every terminal at quiescence.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
fixture, -l's help); the touch check resizes a pane by its grip, there being no rule between panes
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
| |
theme by its name, a field compiled out passed over, no disk asked; touch.dump replaces the hand-written ZON fixture
Fixed for wasm32-freestanding: counts as usize, no threads, stb_image, tape or
host stat there. touch.mjs follows the renderer's 13 tag-layer fields, helix's
retuned colours and the tag column.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
session as it was dumped: a terminal's view, its prompts hidden in text mode, a pane's message, typed text over its history
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
| |
Restore, -l, Handover and the store; dump.zig's hand-written schema gone
A dump is walk.zig's walk of the core with a table of every type it reaches
(fields, enum and union names, number widths), read back by name; terminals
are ghostty's snapshot (screens, history, kitty images); a failed load frees
what it made.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
| |
shows, and with none goes back a pane as Esc does everywhere else; Shift-Esc still goes at once
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
walker copy put back where it was, replicas that apply their own input at once and take the authority's tape as the truth, and a harness of typists over delayed links
src/rollback.zig: the replica core's allocator (`Epoch`) knows every allocation, and while a copy is held puts off frees of what was there before and refuses to grow it in place, so what the core held stays where it was. The copy (`Copy`) is the digest's walk saving the bytes of every allocation it reaches, field by field (the derived caches and this process's own too: a safe build's free writes over what it frees, and the frame arena points at what the epoch then frees), but the queues a step drains and the frame statistics; a file's text, its line index and its undo snapshots are pinned instead (made anew at each edit, never written; now freed raw everywhere), checked unchanged in a safe build. Put back, each allocation's bytes go back over it, the epoch's allocations are freed and its put-off frees forgotten; let go, they are made. Tree-sitter's trees, the C heap's, are held the same way (syntax.held_trees).
src/replica.zig: an `Authority` records its core's every input to a tape in memory and hands each client's input back as a unit (origin, sequence number, its tape); a `Replica` applies its own input at once, as the authority will (update, then pump), recorded by its own tape (tape.zig's speculation mode), and for each unit in order drops its pending head when the authority recorded the same (inputs, host calls and answers: the fast path), else puts the copy back, replays the units since and this one (every digest checked) and applies its pending inputs again. A host call or a syscall stops a speculation: it is answered harmlessly, undone when it returns, and the input waits for the authority's answer; a clock or environment read is a guess the comparison checks; an emulator is the authority's (terminal.zig's writers stop a speculation; a safe build asserts none changed). The view's events (a resize, the pointer) wait. Messages are bytes: no transport yet.
Each client has a view of its own (src/views.zig): the authority goes into it before the client's input (`toView`, taped), the replica's speculation the same, and the copy walks the views not live too (`parked`, each pane's `pv`).
test/replicas.zig (`zig build replicas`): one authority and N replicas, a view each (`--shared` puts them in one), each client typing monkey.zig's mix at 50-200 ms over its own link (half the RTT plus 10% jitter, in order), the authority's pty echoing 2 ms later; gates: no replica diverges, every replica's digest is the authority's at quiescence; reported per RTT: inputs applied at once, stopped, waiting, fast paths, rollbacks (mispredicted, foreign), and what a speculative apply, a copy and a rollback cost. 3 clients x 100 inputs at 30, 80 and 207 ms: no divergence over 12 Debug seeds and 20 ReleaseFast ones with a filled heap; ReleaseFast p99 a speculative apply under 0.2 ms, a rollback under 1.6 ms. `zig build rollback-bench` times the real copy now (take, release, an edit, restore).
What the replicas found, fixed: a release build reads what the heap had where Debug's fill made two cores agree: `col_panes` and `restore_buf` digested undefined (zeroed now), `terminal.State.reply_dropped` never set at create, `Text.sels` and `PendingPipe.ranges` digested past their length (a walker `len` cuts a slice too). PARDES_REPLICA_FILL fills a replica's allocations to show what is left.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
| |
of ~100 KB once file texts are pinned) and what a fork stalls the authority for, which settle open points 3 and 5
`zig build rollback-bench -Dplatform=tty -Doptimize=ReleaseFast` (test/rollback_bench.zig) builds a typical session (a shell with 1 MB of scrollback, three 60 KB files and a 3 MB one, 40 edits) and a big one (14 panes, 18 MB, 4x3 MB and 8 small files, 8 MB of scrollback, 200 edits) in process, then measures the state the digest walk visits, the part of it that is a file's text and its undo snapshots (immutable once made: an edit puts a new buffer in place, a snapshot is a copy, so a copy pins them), and the walk again with those taken out, plus a memcpy of what is left. Typical: 36.3 MB walked, 80 KB to copy, about 0.02 ms; big: 282.5 MB, 96 KB, about 0.045 ms. Then a fork of the big session (431 MB RSS: 3.4 to 8.3 ms) and 64 MB written by the parent under the child (~28 ms of copy-on-write).
test/fork_stall.py does the fork alone, on any system with a Python (the FreeBSD box): N MB written, then fork() timed and 64 MB written under the child, with Linux's THP as set and with 4 KiB pages. 1 GB: 13.3 to 19.6 ms here, 20.4 ms on FreeBSD 15.1; the copy-on-write after it ~1.3 us a page on both.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
-L` can forward, refuses another build's hello in words and hands the connection to its session, which welcomes it and answers pings
The daemon binds `pardes-replica.sock` beside its own (SOCK_STREAM, so ssh can forward it; the SEQPACKET socket that carries fds stays local) once it holds its lock. A replica's first message is a hello (detached/wire.zig, now version 14): the protocol version at offset 0, the client's semantics hash and the session's name. The daemon reads exactly that much and no further, so whatever the client sends next is the session's, keeps up to 16 hellos still on their way (ponytail: one that never comes holds its slot until it hangs up), and refuses in words another protocol, a session nobody has, or another build: every session now says its own hash in its registration (daemon protocol 2), so a mismatch never reaches it. An accepted connection goes to the session over its link (SCM_RIGHTS) and the daemon keeps no copy; the session welcomes it with its pid and name on a thread of its own and answers each ping with a pong, until bye or a hangup. ponytail: that stub is all a session does with a replica until phase 5 proper; it is what times a round trip through the handoff and `ssh -L`.
The semantics hash (wire.semantics) is phase 1's undone item: the protocol, the release and commit, the platform, the build options, every dependency the manifest pins by its content hash (grammars, ghostty, the Unicode tables: build.zig's new `deps` option) and the walker codec's assumptions (pointer width, byte order). Not the OS: a Linux client of a FreeBSD session is the main case. ponytail: an unstamped build has no commit, so two dev trees of one release with the same options are not told apart. `pardes --version` prints it on a second line. The hello lost its grid (a replica's view takes a resize like any other input).
test/daemon.py: a hello of this build welcomed by the session itself (its pid, one fd more in the session and none in the daemon, and back once it hangs up), 50 pings, another build's hello and an unknown session's refused, and `--ping <socket> <session> <pardes> [n]`, which times a hello and n pings on any replica socket (a forwarded one, say).
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|