From 60e07feef401d9044db3a1c925cb9d1f6d20dac9 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Wed, 11 Nov 2026 23:46:02 -0300 Subject: canim: relations as one data-oriented subsystem; aim; the ASan pair; the introduction's chapters From the user. Relations between panes are one subsystem: per-frame tables of places and values in struct-of-arrays, owned by the frame; the kinds one table of data; a resolver of pure passes (join, filter, priority, cut) unit-tested on hand-written tables. Ported kinds draw byte-identical frames; a synthetic map of 4000 places and 6000 values resolves in 0.56 ms against the old table's 5.7. aim, a word holding a code address tied to its row, is the first new kind, off unless a scene turns it on. The ASan pair: one overflow built plain and with ASan, recorded by instruction; the frame as bytes eight a row; the plain run goes on alone in the column, its return address aimed at main's row until the letters reach it; the fault at ret. The introduction's three chapters are built and tested, not yet exported. Annotations, rows and scrolls that changed in one frame now fade; captions stand twelve seconds at most. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_016Y9MNCKgYCGiANnEwcEQxa --- anim/scenes/list.zig | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'anim/scenes/list.zig') diff --git a/anim/scenes/list.zig b/anim/scenes/list.zig index d3d53ed..6a51d45 100644 --- a/anim/scenes/list.zig +++ b/anim/scenes/list.zig @@ -76,7 +76,8 @@ fn frame(s: *anim.Frame) void { says.line(s, "`cur->next` takes `prev`, NULL:\nthe first node is now the end of the list."); at.walk(s, .line, rec.lineMoment(23, loaded)); says.line(s, "Then `prev` and `cur` each step one node along,\nand the loop comes round to the second node."); - at.walk(s, .line, second_trip); + // To the loop's test: the test passing runs with the second trip (a caption is up 12 s at most). + at.walk(s, .line, rec.lineMoment(20, rec.lineMoment(24, first_trip))); // Pacing: the second trip is the same, so hurried; it keeps its rest. says.line(s, "The second node, the same way, faster:\nits `next` turns back to the first."); const third_trip = rec.lineMoment(21, rec.lineMoment(24, second_trip)); @@ -85,7 +86,9 @@ fn frame(s: *anim.Frame) void { says.line(s, "The last node: its `next` turns too,\nback to the node before it."); at.walk(s, .line, rec.lineMoment(23, third_trip)); says.line(s, "`prev` takes the last node, and `cur` runs off the end\nof the list: NULL, so the loop ends."); - at.walk(s, .line, rec.lineMoment(26, third_trip)); + at.walk(s, .line, rec.lineMoment(20, rec.lineMoment(24, third_trip))); + // The test failing, said faster (a caption is up 12 s at most). + at.hurry(s, .line, rec.lineMoment(26, third_trip), .{ .veil = false }); says.line(s, "`head` takes the last node: the same three nodes,\nin the same places, read the other way."); at.walk(s, .line, end); says.close(s); -- cgit v1.3