You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
A release compiler image linked but not yet stamped refuses its own embedded bundles ("embedded bundle 'pcre2' was built for ABI … but this compiler is WITHABISHASTAMPv1XXXX") #1330
Seen on the Windows box while verifying #1329: running out/probe-after.exe (a compiler image produced by with-stage1 build out/gen/main.w -O1 -o probe.exe, i.e. the link output before build.w's link-compiler stamps the .unstamped image) fails at startup with embedded bundle 'pcre2' was built for ABI <digest> but this compiler is WITHABISHASTAMPv1XXXX…. The bundles carry the real ABI digest while the image still carries the placeholder, so the compiler-as-user-program probe (the failure-diagnostics flow in selfhost-windows.yml and any local with build main.w) produces a binary that cannot run. Pre-existing and unrelated to #1147/#1267. Either the probe path must stamp (the stamping step belongs to the link, not to build.w's target), or the check must recognise the placeholder as "unstamped image" with a message that says so.
darwin-aarch64: out/probe-main build re.w (uses std.regex) → error: embedded bundle 'pcre2' was built for ABI 9f50ed35… but this compiler is WITHABISHASTAMPv1XXXX…
windows-x86_64 (win10, W:\verify-1): identical error from out\probe-single.exe build W:/re.w.
Root cause:src/compiler/Link.wlink_stage_select_embedded_bundles compared the bundle's abi-sha with compiler_abi_sha() unconditionally, while Compilation.load_link_bundles already skipped the comparison for an unstamped image.
Fix: one rule, AbiStamp.abi_identity_refuses_bundle(self_abi, bundle_abi) — a stamped identity refuses another ABI (#761), an unstamped image links its bundles unchecked, as a hand-linked compiler keeps no generation (#1815); both link paths read it. test/internals/link_embedded_bundle_abi_test.w pins the three cases (red under the old rule, green with the fix).
Verified: with the fix, the unstamped probe prints WITHABISHASTAMPv1XXXX… for version --abi-sha and links the std.regex program, which prints match — on darwin-aarch64 (out/probe-fix) and on win10 (W:\verify-2, patch applied on 30f89aa, src\main build green, out\probe-fix.exe).
Activity
ehartford commentedon Oct 2, 2026
Reproduced on main 1688728 on both hosts and fixed on branch
fix-1330(tip 4a3b956, rebased on 30f89aa, gate green; not pushed).Repro (unstamped probe image =
with-stage1 build out/gen/main.w -O1 -o probe):out/probe-main build re.w(uses std.regex) →error: embedded bundle 'pcre2' was built for ABI 9f50ed35… but this compiler is WITHABISHASTAMPv1XXXX…W:\verify-1): identical error fromout\probe-single.exe build W:/re.w.Root cause:
src/compiler/Link.wlink_stage_select_embedded_bundlescompared the bundle'sabi-shawithcompiler_abi_sha()unconditionally, whileCompilation.load_link_bundlesalready skipped the comparison for an unstamped image.Fix: one rule,
AbiStamp.abi_identity_refuses_bundle(self_abi, bundle_abi)— a stamped identity refuses another ABI (#761), an unstamped image links its bundles unchecked, as a hand-linked compiler keeps no generation (#1815); both link paths read it.test/internals/link_embedded_bundle_abi_test.wpins the three cases (red under the old rule, green with the fix).Verified: with the fix, the unstamped probe prints
WITHABISHASTAMPv1XXXX…forversion --abi-shaand links the std.regex program, which printsmatch— on darwin-aarch64 (out/probe-fix) and on win10 (W:\verify-2, patch applied on 30f89aa,src\main buildgreen,out\probe-fix.exe).Link: an unstamped compiler image links its embedded bundles unchecke…
Link: an unstamped compiler image links its embedded bundles unchecke…
Link: an unstamped compiler image links its embedded bundles unchecke…