Skip to content

vms-fe4: self-host spine #5 — MMK plans a real multi-TU OVMX component; toolchain builds it byte-identical twice - #470

Merged
baron-3dl merged 1 commit into
mainfrom
vms-fe4-mmk-component-build
Aug 13, 2026
Merged

baron-3dl merged 1 commit into
mainfrom
vms-fe4-mmk-component-build

Conversation

@baron-3dl

Copy link
Copy Markdown
Contributor

Self-host spine #5 (vms-fe4) — builds on #4 (vms-b23 MMK mailbox drive), #3 (vms-ca9 LIBRARIAN/.OLB)

Picks a real multi-TU OVMX component — the freestanding runtime (src/libvmssys vms_string.c / vms_snprintf.c / vms_math.c, Rule 3 freestanding, + a driver) — writes an MMK descrip.mms for it, and proves the two halves that are host-provable, precisely flagging the QEMU execution half for spine #6.

Component + descrip.mms

  • tests/toolchain/component/OVMXRT.MMS (committed): MMS/MMK syntax — macros $(NAME), automatic macros $(MMS$TARGET)/$(MMS$SOURCE), target : deps + TAB actions — grounded in the MadGoat MMK manual + public HP/VSI MMS Reference Manual (clean-room, Rule 8). Builds: 4× TCC compile → LIBRARIAN /CREATELINK.
  • OVMXRTDRV.C: freestanding driver calling one entry from each TU (independent oracle 6×36=216).

What's proven this session (host, green)

  1. toolchain-mmk-component-plan — the shipped MMK.EXE reads OVMXRT.MMS through OVMX RMS, expands the MMS macros, builds the dependency graph, and emits the full multi-TU plan (/NOACTION): four TCC compiles, then the LIBRARIAN archive, then the LINK, in dependency order (all compiles < archive < link), byte-identical across two runs. Zero bash — MMK drives it. (Spine dcl: SHOW DEVICE row byte-exact + create_dir leak fix (vms-b9f round 5) #4's single-TU parse proof, scaled to a real multi-TU + library component.)
  2. toolchain-mmk-component-build — the OVMX-native LIBRARIAN.EXE + LINK.EXE build the component's .OLB and image BYTE-IDENTICALLY across two independent builds (cmp clean on both) from the real component objects, with selective pull (2 of 3 members: SNPRINTF+STRING, not MATH), image validated by OVMXDUMP. LIBRARIAN zeroes the ar mtime/uid/gid fields. With TCC.EXE's compile determinism (run_tcc_selfhost gen2==gen3), the whole TCC → LIBRARIAN → LINK chain is reproducible — the byte-identical-twice bar for the build output.

Both are new host ctests under tests/toolchain/ (labels toolchain;mmk;librarian;link;selfhost). Full toolchain label: 7/7 green.

Residual gap → spine #6 (vms-d1b, the CI gate)

MMK's real drive (ovmx_mmk_sp.c) executes via a persistent DCL over VMS mailboxes, so it needs a real /dev/vms (QEMU) — with none it honestly fails SS$_NOSUCHDEV (Rule 9/INV-6). The MMK-driven execution (a QEMU test_syssvc_mmk_build.c extending spine #4's test_syssvc_mmk_drive.c so the action is a real TCC/LNK build), plus toolchain staging into the initramfs, a static-musl TCC.EXE target, spawned-DCL foreign-command setup, first-ever TCC-in-QEMU, and the byte-identical-in-QEMU assertion, are specified precisely in docs/design-self-host-spine5-mmk-component.md. Per Rule 6/7 this PR ships no unproven/red QEMU suite — it lands the host-provable halves and the exact execution spec.

BUILD.COM is not deleted yet — its deletion follows the spine #6 execution proof.

🤖 Generated with Claude Code

…t; toolchain builds it byte-identical twice

MMK.EXE now drives the PLAN for a real multi-translation-unit OVMX component —
the freestanding runtime (src/libvmssys vms_string/vms_snprintf/vms_math + a
driver), described by the committed MMS descrip.mms tests/toolchain/component/
OVMXRT.MMS: four TCC compiles, a LIBRARIAN archive, a LINK, in dependency order,
byte-identical across two runs. Zero bash in the plan — MMK drives it. This is
spine #4's single-TU parse proof scaled to a real multi-TU + library component.

The OVMX-native LIBRARIAN.EXE + LINK.EXE build that component's .OLB and image
BYTE-IDENTICALLY across two independent builds (cmp clean) on the real component
objects, with selective member pull (2 of 3 members). LIBRARIAN zeroes the ar
mtime/uid/gid fields; with TCC.EXE's proven compile determinism (run_tcc_selfhost
gen2==gen3), the whole TCC->LIBRARIAN->LINK chain is reproducible — the
byte-identical-twice bar for the build OUTPUT.

New host ctests (both green): toolchain-mmk-component-plan (MMK_EXE) and
toolchain-mmk-component-build (LIBRARIAN/LINK/OVMXDUMP on the real objects).

Residual gap (spine #6, vms-d1b, the CI gate): MMK's mailbox-driven DCL EXECUTION
of the plan requires a real /dev/vms (QEMU); that + first-ever TCC-in-QEMU,
toolchain staging into the initramfs, spawned-DCL foreign-command setup, and the
byte-identical-in-QEMU assertion are specified precisely in
docs/design-self-host-spine5-mmk-component.md. No unproven/red QEMU suite is
shipped (Rule 6/7).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@baron-3dl
baron-3dl merged commit 6a428a5 into main Aug 13, 2026
61 checks passed
baron-3dl added a commit that referenced this pull request Aug 13, 2026
…ve (#472)

Bump OVMX_PRODUCT_VERSION V0.4-2 → V0.4-3. 15 PRs since V0.4-2. Headline:
the self-host toolchain now BUILDS — MMK.EXE drives real compile+link
inside OVMX against a live executive.

  SELF-HOST #4 COMPLETE  MMK.EXE genuinely drives compile+link builds vs real
                         /dev/vms (#464 capstone). Full exec-drive substrate:
                         async AST delivery + interruptible $HIBER (#457),
                         IO$M_NOW (#458), DCL-over-mailbox (#460), + crash fixes
                         #463 (32→64 ptr-width) / #464 (IO$M_NOW func-code mask).
                         Freeze-join fix (#459). Component build host-proven (#470).
  UX FIDELITY            SHOW CPU (#465), file protection SET/display (#467),
                         RECALL readline-independent (#468), DCL scripting
                         $STATUS/%X + CALL/SUBROUTINE + DECK/EOD (#469),
                         DIRECTORY wildcards/ellipsis (#461).
  + swept other threads' merged work

Self-host spine #5/#6 (MMK-drives-a-real-component IN QEMU) in flight.

Co-authored-by: alice <alice@workspace.local>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant