| |
|
|
|
|
|
|
|
|
| |
blocked for good while keys still work
vaxis's event queue woke one blocked writer, and only on the pop from full. The tty's loop has two writers on it: a pane's pty reader, and the input reader posting the wake for a frame's answered status request (FrameAck). Under `yes` both block on the full queue; the loop then takes a whole batch, its first pop wakes one of them, the rest wake no one, and the pty reader waits for good: the program in the pane blocks writing to its pty, the pane stops moving, and every key still works. It happened from about 400 KB of output, every time at 1 MB, through the snapshot harness's pty as through a terminal.
build.zig patches vaxis's src/queue.zig at build time, count-checked as its Parser.zig and Vaxis.zig are: a pop that makes room wakes every blocked writer. A test (src/vaxis_input.zig) empties a full queue in one batch with two writers waiting and requires both to land. `yes | head -c N` through a bash pane in tty mode now finishes at 1 MB, 10 MB, 100 MB (16 s) and 1 GB (179 s, test/perf.zig --live).
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
|
|
map, vaxis_input.zig, for the tty, the gui and the board
The vaxis-to-Event key mapping was copied in tty.zig, gui.zig and esp32p4.zig, and the copies had drifted: the gui's (its stdin feed, which test windows and a gui started in a terminal read) had 9 arms against the tty's 26, without the function keys, Insert or the keypad, so they reached a terminal pane as private-use codepoints. vaxis_input.zig holds effCp, mapKey and keyEvent once; the gui posts through postKey, and a test runs F5, Insert and the keypad's Up through it into a terminal pane.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|