Skip to content

vms-4a6: resolve the main executable's own .vms$wimp at activation - #694

Merged
baron-3dl merged 1 commit into
mainfrom
fix/vms-4a6-exe-wimp
Aug 21, 2026
Merged

baron-3dl merged 1 commit into
mainfrom
fix/vms-4a6-exe-wimp

Conversation

@baron-3dl

Copy link
Copy Markdown
Contributor

resolve_weak_imports() iterated only loaded producers; the main executable (g_exe) was never in the set, so an executable's OWN weak-by-name imports were silently dropped → an executable's resolvable weak import stayed 0 and its first call jumped through a null GOT cell to 0x0.

Factor the per-image .vms$wimp walk into resolve_wimp_for(base, wimp_addr); run it for every producer AND for g_exe; register g_exe.wimp_addr in activate_symbol_vector. Fail-honest preserved (absent → 0); strong .vms$imp binding untouched. New causal gate run_exe_weak_import_activation.sh (wired into the weak-import-activate job): present→bound (exit 5), absent→0; reverting imgact.c makes the positive case return 0.

Note: this is NOT the cpptest keystone. The vms-4a6 investigation (descriptor dump + live gdb) found the original 'unbound weak malloc' premise was a misattribution — malloc is a STRONG import (.vms$imp[17], DECC$SHR) and its cell binds fine; cpptest's real crash is DECC$SHR/musl pthread-ABI (vms-ad70, GCC lane). This closes a separate, real executable-.vms$wimp binding gap that exe-weak-import binding needs.

🤖 Generated with Claude Code

resolve_weak_imports() iterated only g_prods[] (loaded producers); the main
executable (g_exe) was never in it, so an executable's OWN weak-by-name imports
were silently dropped -- an executable's resolvable weak import stayed 0 and its
first call jumped through a null import-GOT cell to address 0 (the C++ first-light
crash class, vms-70d/cc1: whole-archived libstdc++/libgcc weak-references a
universal a producer exports).

Factor the per-image .vms$wimp walk into resolve_wimp_for(base, wimp_addr) and
run it for every producer AND for g_exe. Register the executable's mapped
.vms$wimp (g_exe.wimp_addr) in activate_symbol_vector while the section headers
are readable. Fail-honest is preserved unchanged: a weak import no loaded producer
exports still resolves to 0. Strong (.vms$imp) binding is untouched.

New gate run_exe_weak_import_activation.sh drives the symmetric case the producer
test (run_weak_import_activation.sh) never covered: an executable whose own
.vms$wimp names a universal reached only via a transitively-loaded producer.
Present -> bound (exit 5), absent -> 0 (fail-honest, exit 0). Verified causally:
reverting the imgact.c change makes the positive case return 0 (unbound).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@baron-3dl
baron-3dl merged commit a2cfd77 into main Aug 21, 2026
96 checks passed
baron-3dl added a commit that referenced this pull request Aug 22, 2026
)

Bump OVMX_PRODUCT_VERSION V0.5 -> V0.5-1. Point release packing the V0.5-x train:
the NetBSD/VAX executive Files-11 ODS-2 ACP flip completing the flip on all three
substrates (#690, vms-d9c green), Alpha authentic binary-SYSUAF login + standing
green-by-SHA CI gate (#691/#692), C++ first-light 3-way-gated (#695), the
executable-own .vms$wimp binding fix (#694), and the 1.0=hardening roadmap
re-scope (#693). Release notes: docs/release-notes-0.5-1.md.

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
baron-3dl added a commit that referenced this pull request Aug 22, 2026
* release: OVMX V0.5-1 — 3-substrate flip complete + C++ first-light

Bump OVMX_PRODUCT_VERSION V0.5 -> V0.5-1. Point release packing the V0.5-x train:
the NetBSD/VAX executive Files-11 ODS-2 ACP flip completing the flip on all three
substrates (#690, vms-d9c green), Alpha authentic binary-SYSUAF login + standing
green-by-SHA CI gate (#691/#692), C++ first-light 3-way-gated (#695), the
executable-own .vms$wimp binding fix (#694), and the 1.0=hardening roadmap
re-scope (#693). Release notes: docs/release-notes-0.5-1.md.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* roadmap: reconcile for V0.5-1 (regenerate doc + build json from rd/tags)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

---------

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