Files
LithosAnanake/kernel/src
rajamesandClaude Opus 5.5 66b26f823c fix(v4.0.0): step 6e final review -- texts begun in order; a word no one will read lets its writer go; a cut wire wakes a wait for room; a full console wire is a refusal, not a fault
The final review of step 6e, by a fresh reviewer told to break it, and
what was ruled: fix them all, test first.  Each has a test that failed
before the mend.

- Two texts from one node could be begun in the wrong order when room
  for their answers came between the node's look at the first and at the
  second.  Texts whose answers go by the same port are begun in the order
  they came: (D-MASK), quit.v4.  102 of 700 timings were wrong before.
- A word written with PORT! to a node that speaks whole messages, or to
  a console's port, blocked its writer for ever and cut off every node
  beyond it.  It is error 18 now, whether that node is asleep, running
  or stuck: fabric.c, node.c.
- A node asleep for room on one wire is woken when another of its wires
  is cut.
- A line there was no room for on the lone node's wire was reported as a
  fault and ended the hosted program.  It is Message refused, and the
  prompt comes back: V4_BOOT_LINE_REFUSED.  hosted-check has the case;
  no bare-metal boot has typed it.
- Ruled: text behind held output for the same port is refused though it
  would fit.  MESH.md 7d.4 said otherwise and is corrected.
- The removal test also cuts and re-makes a wire, and has an exchange in
  which output is held at a full wire: 26,814 disturbances in all.
- MESH.md and v4/README.md no longer say that a stuck node holds up no
  other node, that only printing waits, or that no node is left waiting
  on one that is gone; 7d.6 lists the limits and what the products do
  that they did not before.

make -C v4 test and sanitize at both widths, hosted-check, lint.  Three
bare-metal boots: logs/20261013-194827 (amd64), -195131 (aarch64),
-195518 (riscv64).  POST 538 of 538, word_count=317,
dict_hash=0xe5a57f3eb72ff94a on all six; the three sessions are the same
character for character.  The boots were built with the working tree's
uncommitted change to kernel/Makefile that adds the ISA to the kernel's
version line.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 20:02:33 -04:00
..

src/starkernel/

LithosAnanke — the bare-metal UEFI kernel that boots StarForth directly on hardware (amd64/aarch64/riscv64). Built only via Makefile.starkernel; the only valid acceptance test is the three-arch QEMU boot (see .claude/CLAUDE.md), never make test.

  • kernel_main.c — kernel entry point, driving the boot milestones (console init, PMM, VMM, interrupts, timers, kmalloc heap, VM bootstrap).
  • repl.c — kernel REPL.
  • doe_log.c — kernel-side DoE (Design of Experiments) metrics logging.

Subdirectories:

  • arch/{amd64,aarch64,riscv64}/ — per-architecture support (APIC/GIC/ PLIC interrupt controller, timers, boot/ISR assembly).
  • boot/ — UEFI loader, ELF loading, kernel command-line parsing.
  • capsule/ — capsule birth/run/load/validate pipeline.
  • hal/ — hardware-abstraction-layer implementation (console, framebuffer, VT100, memory, host services).
  • hash/ — XXHash64 content-addressing implementation.
  • math/ — kernel-build Q48.16 fixed-point arithmetic.
  • memory/ — physical/virtual memory managers and the kernel heap.
  • pci/ — PCI bus enumeration.
  • virtio/ — VirtIO block device driver.
  • vm/ — kernel VM subsystem (bootstrap, core interpreter, parity logging, capsule arena).

See include/starkernel/README.md for the corresponding headers.