10 Commits
Author SHA1 Message Date
Claude abfb30d0c4 logs: the developer protocol on dd6c393a -- PASS, all eight stages
Build / Image PC (push) Successful in 10m45s
Build / Image RASPI (push) Successful in 9m59s
Build / Image MILKV (push) Successful in 9m16s
Build / v4 tests (32- and 64-bit cells) (push) Successful in 23m13s
Acceptance / Acceptance (pull_request) Successful in 35m0s
A1 (the hook at call), the merge of master (the six runner.capacity
comments) and HEAT-OP/ANTICLOCK (#189). POST 538/538 on the four boots;
word_count 320 and dict_hash 0xd148437fb39a1afd on all three
architectures (318 and 0x8c92508f748f99cf before: the two new words);
test-32 39 programs 0 failures; proofs; images; documents, the
dictionary covering all 320 live words. logs/20261113-005100/PROTOCOL.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017RzZgrf7V7Zk2iczBXDRbm
2026-11-13 01:22:02 +00:00
Claude dd6c393a89 feat(v4): HEAT-OP[0..31] and ANTICLOCK, read by HEAT-OP@ and ANTICLOCK@
#189 -- Captain Bob, 2026-11-12: "Add HEAT-OP. If it's a huge performance
hit, we'll revert it. If not ... it stands"; a full 33-cell array, as
DECOMPOSITION.md section 7 draws it; the Stadium feed is Phase 1's.

- node.h/node.c: v4_node_heat_regs_attach; a data fetch from base+k gives
  opcode k's count, base+32 the anti-clock (the low cell at 32 bits); a
  store changes nothing. Reset detaches them.
- host_map.h: HEAT_REG at word 13824, in what was free between the
  dictionary space and SEND_TEXT; the compile-time check covers it.
  Nothing moved. map-*.f18: HEAT-OP 13824, ANTICLOCK 13856.
- image.h/image.c/mkmap.c: the image carries the address; v4_image_born
  attaches the node's own counts.
- system.f18: HEAT-OP@ ( op -- n ), op mod 32; ANTICLOCK@ ( -- n ).
  word_count 318 -> 320 (hosted 317 -> 319): dict_hash changes.
- v4-dictionary.tsv: both words; DECOMPOSITION.md 7 records the build.

Also in this batch:
- Makefile: make init installs qemu-user -- hosted-check needs it
  (Captain Bob: "Add to make init now").
- .claude/memory/rules.md, rule 5: stop and ask when something comes up
  (Captain Bob: "you are supposed to stop and ask").

Tests first (logs/20261113-005047/heat-op): test_node did not compile;
test_host_quit 3 of 1337 failed. Suite: 199 programs, 7448554 checks, 0
failures; hosted-check, the three alike. Timing: no measurable cost.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017RzZgrf7V7Zk2iczBXDRbm
2026-11-13 00:50:56 +00:00
Claude 9710bd1779 Merge master into StarForth-v4.0.0: the six runner.capacity comments
Captain Bob, 2026-11-13: "I merge master in". PR 164 could not merge:
master's six comment-only commits of 2026-11-11 (751bfe26..268e5593,
"record runner.capacity: 1 decision ... (FABRIC-3, #140)") edit the
concurrency blocks the branch deletes for #140 ("It should be global").

Resolved in every workflow for the branch -- no concurrency group --
with master's fact kept as a line of the #140 comment: the capacity is
explicit in the runner's config.yaml, runner.capacity: 1. Each file
parses; scripts/test_acceptance_signing.sh passes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017RzZgrf7V7Zk2iczBXDRbm
2026-11-13 00:14:21 +00:00
Claude 3c97534c8b feat(v4): a hook at call, for whoever runs the node
Plan 2026-10-20 (ENGINE step 4), Task A1, for #189 -- Captain Bob,
2026-11-12: the physics blocks alpha.5; order A, 1, 2, then 7.

- exec.h/exec.c: v4_call_hook, es->on_call/on_call_ctx; called at `call`
  once the return address is pushed, before P moves. NULL: as before.
- heat.h/heat.c: the per-call-target table (4096 slots, no capsule word
  counted), its freeze mask and v4_heat_call_* go (ENGINE.md step 3: "The
  per-call-target count goes"); the kernel will keep a word's accounts.
- tests: test_call_hook_sees_every_call, seen to fail first (no on_call);
  test_heat's per-call tests go with the table.
- the plan records today's rulings (order; HEAT-OP: both, a full array).

Suite (logs/20261112-225951/v4-tests): test, test-32, sanitize, 0
failures; hosted-check, the three alike. amd64 boot: POST 538/538,
dict_hash 0x8c92508f748f99cf, unchanged -- nothing sets the hook yet.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017RzZgrf7V7Zk2iczBXDRbm
2026-11-12 23:01:52 +00:00
rajames 268e55937e ci: record runner.capacity: 1 decision in nightly-docs.yml (FABRIC-3, #140) 2026-11-11 21:35:32 +00:00
rajames b0e33c9a93 ci: record runner.capacity: 1 decision in release.yml (FABRIC-3, #140) 2026-11-11 21:35:25 +00:00
rajames 265d65b5f8 ci: record runner.capacity: 1 decision in acceptance.yml (FABRIC-3, #140) 2026-11-11 21:35:21 +00:00
rajames 314cbc57bc ci: record runner.capacity: 1 decision in runner-image.yml (FABRIC-3, #140) 2026-11-11 21:35:15 +00:00
rajames 96a1ad7d80 ci: record runner.capacity: 1 decision in nightly.yml (FABRIC-3, #140) 2026-11-11 21:35:09 +00:00
rajames 751bfe2675 ci: record runner.capacity: 1 decision in build.yml (FABRIC-3, #140) 2026-11-11 21:34:30 +00:00
59 changed files with 381 additions and 174 deletions
+4
View File
@@ -9,6 +9,10 @@
not following it. I had summarised the foreground rule to Bob and broke it anyway.
3. Every log and every CSV is evidence and is committed — passing, failing, stopped.
4. Never create a branch, never stash, never fix unasked, never push without Bob saying push.
5. **When something comes up -- a missing tool, a surprise, anything not in the plan -- STOP AND ASK
before acting.** (Bob, 2026-11-12: "you are supposed to stop and ask when something comes up ... What
if I had missed that message?") I installed qemu-user unasked when hosted-check could not find
qemu-aarch64, and only said so afterwards, in a summary. Telling him after is not asking him first.
Source of authority: `.claude/CLAUDE.md` (wins), then the FABRIC record (`docs/fabric/`, FABRIC-3 living),
then `docs/v4.0.0/`, `docs/reference/ROADMAP.md`, `boards/BRINGUP.md`. Code wins over all documents.
+1
View File
@@ -21,6 +21,7 @@ on:
# (starshipos-vps) has capacity 1, so every job of every workflow waits its turn in Gitea's queue
# and none is cancelled; a runner-image rebuild still blocks the rest (2026-11-07). A shared
# concurrency group kept only one waiting run, and each run that joined cancelled it.
# The capacity is explicit in the runner's config.yaml: runner.capacity: 1 (FABRIC-3, 2026-11-11).
jobs:
acceptance:
+1
View File
@@ -17,6 +17,7 @@ on:
# (starshipos-vps) has capacity 1, so every job of every workflow waits its turn in Gitea's queue
# and none is cancelled; a runner-image rebuild still blocks the rest (2026-11-07). A shared
# concurrency group kept only one waiting run, and each run that joined cancelled it.
# The capacity is explicit in the runner's config.yaml: runner.capacity: 1 (FABRIC-3, 2026-11-11).
jobs:
image:
+1
View File
@@ -18,6 +18,7 @@ on:
# (starshipos-vps) has capacity 1, so every job of every workflow waits its turn in Gitea's queue
# and none is cancelled; a runner-image rebuild still blocks the rest (2026-11-07). A shared
# concurrency group kept only one waiting run, and each run that joined cancelled it.
# The capacity is explicit in the runner's config.yaml: runner.capacity: 1 (FABRIC-3, 2026-11-11).
jobs:
docs:
+1
View File
@@ -24,6 +24,7 @@ on:
# (starshipos-vps) has capacity 1, so every job of every workflow waits its turn in Gitea's queue
# and none is cancelled; a runner-image rebuild still blocks the rest (2026-11-07). A shared
# concurrency group kept only one waiting run, and each run that joined cancelled it.
# The capacity is explicit in the runner's config.yaml: runner.capacity: 1 (FABRIC-3, 2026-11-11).
jobs:
nightly:
+1
View File
@@ -22,6 +22,7 @@ on:
# (starshipos-vps) has capacity 1, so every job of every workflow waits its turn in Gitea's queue
# and none is cancelled; a runner-image rebuild still blocks the rest (2026-11-07). A shared
# concurrency group kept only one waiting run, and each run that joined cancelled it.
# The capacity is explicit in the runner's config.yaml: runner.capacity: 1 (FABRIC-3, 2026-11-11).
jobs:
release:
+1
View File
@@ -21,6 +21,7 @@ on:
# (starshipos-vps) has capacity 1, so every job of every workflow waits its turn in Gitea's queue
# and none is cancelled; a runner-image rebuild still blocks the rest (2026-11-07). A shared
# concurrency group kept only one waiting run, and each run that joined cancelled it.
# The capacity is explicit in the runner's config.yaml: runner.capacity: 1 (FABRIC-3, 2026-11-11).
jobs:
image:
+4 -1
View File
@@ -273,8 +273,11 @@ write_stick:
# first, the nightly documents the second (scripts/nightly.sh).
INIT_DOCS ?= 1
INIT_PROOFS ?= 1
# qemu-user: `make -C v4 hosted-check` runs the aarch64 and riscv64 hosted builds under it
# (qemu-aarch64, qemu-riscv64; Captain Bob, 2026-11-12: "Add to make init now").
INIT_COMMON := build-essential make git git-lfs python3 curl ca-certificates xz-utils \
xorriso mtools gdisk dosfstools fdisk
xorriso mtools gdisk dosfstools fdisk \
qemu-user
INIT_DOCPKGS := pandoc latexmk texlive-xetex texlive-latex-base texlive-latex-recommended \
texlive-latex-extra texlive-pictures texlive-fonts-recommended lmodern \
fonts-dejavu fonts-dejavu-extra doxygen graphviz
+2
View File
@@ -112,6 +112,8 @@ constant HEND 63248
constant -HFLOOR -63186
constant DSTACK-DEPTH 16369
constant RSTACK-DEPTH 16368
constant HEAT-OP 13824
constant ANTICLOCK 13856
constant CFBASE 16288
constant CFEND 16320
constant ROM-UM* 16384
+2
View File
@@ -112,6 +112,8 @@ constant HEND 63248
constant -HFLOOR -63186
constant DSTACK-DEPTH 16369
constant RSTACK-DEPTH 16368
constant HEAT-OP 13824
constant ANTICLOCK 13856
constant CFBASE 16288
constant CFEND 16320
constant ROM-UM* 16384
+12
View File
@@ -8,9 +8,21 @@
\ that starts below the address it holds
\ VOC-LINK word address of the variable: the newest vocabulary, or 0
\ (BOOT) word address of two cells: DP and (LATEST) as the loader left them
\ HEAT-OP ANTICLOCK word addresses of HEAT-OP[0] and ANTICLOCK, the heat
\ registers (DECOMPOSITION.md section 7): read-only
set HDR-NFA here ", FENCE #, 8 #, HDR-NFA #, HDR-LINK set HDR-LINK here : FENCE' FENCE ;
\ ---- the heat registers (DECOMPOSITION.md section 7; #189) -----------------------
\ Captain Bob, 2026-11-12: "Add HEAT-OP". The node counts every instruction it
\ retires, by opcode, and the anti-clock ticks once for each; these read them.
\ ( op -- n ) how many times opcode op has retired; op is taken mod 32
set HDR-NFA here ", HEAT-OP@ #, 0 #, HDR-NFA #, HDR-LINK set HDR-LINK here
: HEAT-OP@ 31 and HEAT-OP + b! @b ;
\ ( -- n ) the anti-clock: one tick per instruction retired
set HDR-NFA here ", ANTICLOCK@ #, 0 #, HDR-NFA #, HDR-LINK set HDR-LINK here
: ANTICLOCK@ ANTICLOCK b! @b ;
\ ---- vocabularies (FORTH-79) ----------------------------------------------------
\ A vocabulary is two cells: its head -- the xt of its newest entry, or 0 --
\ and the address of the vocabulary defined before it, or 0. VOC-LINK holds
+2
View File
@@ -100,6 +100,7 @@ AGAIN ( -- ) Compile-only: end a BEGIN loop that repeats for ever.
ALIGN ( -- ) Align the dictionary pointer to the next cell.
ALLOT ( n -- ) Reserve n cells of dictionary space.
AND ( x1 x2 -- x3 ) Bitwise and.
ANTICLOCK@ ( -- n ) The anti-clock: how many instructions the node has retired, one tick each (#189).
AWAIT ( node -- how ) Wait for the node's word on how its text ended: 0 QUIT, 1 completed, otherwise an error.
BASE ( -- addr ) Variable: the number base for conversion in and out.
BEGIN ( -- ) Compile-only: mark the start of a loop (UNTIL, WHILE ... REPEAT, AGAIN).
@@ -170,6 +171,7 @@ FLUSH ( -- ) Write every changed block (SAVE-BUFFERS).
FORGET ( -- ) FORGET xxx: remove xxx and every word defined after it, never below FENCE.
FORTH ( -- ) Make FORTH, the primary vocabulary, the CONTEXT vocabulary.
GONE ( n node -- ) Tell the node that node n is gone; it acts on that only if this node is its centre.
HEAT-OP@ ( op -- n ) How many times opcode op (taken mod 32) has retired: its heat counter, HEAT-OP[op] (#189).
HERE ( -- addr ) The address of the next free dictionary cell.
HEX ( -- ) Set BASE to sixteen.
HIDDEN ( -- ) Hide the newest entry: it cannot be found until revealed.
Can't render this file because it contains an unexpected character in line 10 and column 3.
+8
View File
@@ -1090,6 +1090,14 @@ expiry, moved into logic. A packet type `SOS` is reserved for any node to emit.
Addresses are assigned in the node memory map (D-4). Names only here.
> **2026-11-12 (#189; Captain Bob: "Add HEAT-OP", a full array):** `HEAT-OP[0..31]` and `ANTICLOCK`
> are built: 33 read-only registers on the node (`v4_node_heat_regs_attach`, `v4/include/v4/node.h`),
> at word 13824 in the map the system is built with (`v4/tests/host_map.h`, `HEAT_REG`), read by
> `HEAT-OP@ ( op -- n )` and `ANTICLOCK@ ( -- n )` (`capsules/v4/sys/system.f18`). At 32-bit cells a
> read gives the low cell of the 64-bit count. `HEAT-CALL[...]`'s per-call-target table is gone from
> the engine (plan 2026-10-20, Task A1): a call's target goes to the hook at `call`, and the kernel
> keeps a word's accounts. Feeding the opcode counts to the Stadium is Phase 1's, measured.
| Register | Access | Contents |
| --- | --- | --- |
| `HEAT-OP[0..31]` | R | Per-opcode retirement heat. |
@@ -55,6 +55,13 @@ minted, and the boot recognises it. Today it does not: the drive QEMU attaches b
`disk/thumbdrives/zuse-thumb-ident.img`, is all zeros (bleached, `e56974e0`), and the v4 boot reads
no thumbdrive and prints its prompt with no identity. See "The identity gate" below.
**RULED 2026-11-12 (Captain Bob), #189** -- v4 has no Compudynamics beyond its heat counters, and it
"blocks alpha.5": the physics comes first. **Order: Part A, Phase 1, Phase 2, then Phase 7**; Phases
3 to 5 follow after alpha.5. And **HEAT-OP**: "Add HEAT-OP. If it's a huge performance hit, we'll
revert it" -- both: `HEAT-OP[0..31]` and `ANTICLOCK` readable as registers now, a full 33-cell array
(`DECOMPOSITION.md` §7), and fed to the Stadium in Phase 1, measured, kept or reverted on the
numbers.
**Q1. What "Hera, Hermes, Artemis are kernel" means in v4.**
*Recommend:* each is a function of the kernel, not a VM or node with a capsule of its own:
- **Hera** — process management: the registry, births, `NODE-KILL`/`SLEEP`/`WAKE` and who may ask
@@ -160,11 +167,11 @@ acceptance. Only Part A is written in tasks below; it does not depend on Q1 to Q
**Interfaces:** Produces `typedef void (*v4_call_hook)(void *ctx, v4_node *n, v4_cell target);` and, in `v4_exec_state`, `v4_call_hook on_call; void *on_call_ctx;`. Called at `V4_OP_CALL` after the return address is pushed, before `n->p` moves. NULL = no hook.
- [ ] **Step 1: Failing test** `test_call_hook_sees_every_call`: a programme calling three routines, one twice; the hook records the four targets in order; with `on_call = NULL` the result is the same.
- [ ] **Step 2:** `make -C v4 test` — FAIL (no `on_call`).
- [ ] **Step 3:** Add the hook; remove `v4_heat_on_call`, `call[]`, the freeze mask and `v4_heat_call_*`, and their tests.
- [ ] **Step 4:** Suite passes at both widths and under sanitizers; `hosted-check` unchanged.
- [ ] **Step 5:** Commit `feat(v4): a hook at call, for whoever runs the node`. (No boot change: nothing sets the hook on bare metal yet. One amd64 boot to confirm POST 538/538 and the same `dict_hash`.)
- [x] **Step 1: Failing test** `test_call_hook_sees_every_call`: a programme calling three routines, one twice; the hook records the four targets in order; with `on_call = NULL` the result is the same.
- [x] **Step 2:** `make -C v4 test` — FAIL (no `on_call`).
- [x] **Step 3:** Add the hook; remove `v4_heat_on_call`, `call[]`, the freeze mask and `v4_heat_call_*`, and their tests.
- [x] **Step 4:** Suite passes at both widths and under sanitizers; `hosted-check` unchanged.
- [x] **Step 5:** Commit `feat(v4): a hook at call, for whoever runs the node`. (No boot change: nothing sets the hook on bare metal yet. One amd64 boot to confirm POST 538/538 and the same `dict_hash`.)
### Task A2: Words that are checked are called
Binary file not shown.
+5
View File
@@ -0,0 +1,5 @@
# Task A1's v4 suite, 2026-11-12 (#189)
test_exec-before.log: test_exec.c against the engine before the hook: does not compile (no on_call).
suite-test-test32-sanitize.log: make -C v4 test test-32 sanitize hosted-check; stopped by the session's 30-minute background limit inside san-64-test_host_depth.c, every program before it 0 failures.
suite-sanitize-rest.log: the sanitizer runs from san-64-test_host_depth.c on (39 programs, 810885 checks, 0 failures); its hosted-check stopped at qemu-aarch64 not installed.
hosted-check.log: hosted-check rerun with qemu-user installed: the three boot identically, depthsweep 230 runs 0 failures.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+6
View File
@@ -0,0 +1,6 @@
# HEAT-OP[0..31] and ANTICLOCK (#189), 2026-11-12/13
test_node-before.log: test_node.c before the registers: does not compile (no heat_reg, no attach).
test_host_quit-before.log: the map entries in, the words not yet: 3 of 1337 fail (HEAT-OP@, ANTICLOCK@ unknown).
suite.log: make -C v4 test test-32 sanitize hosted-check: 199 programs, 7448554 checks, 0 failures; the three hosted builds alike.
suite-stopped-by-container-restart.log: the first run of the same, cut off by the session's container restart at 110 programs, 0 failures.
timing.txt: the hosted amd64 boot (POST 538), five runs each, alternating: OLD = 3c97534c, NEW = with HEAT-OP. Median 3.734 s / 3.731 s; instructions 59145258 / 59302047 (+0.27%, the two words' assembly). No measurable cost: by Captain Bob's rule it stands.
Binary file not shown.
Binary file not shown.
Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More