Skip to content

Self-host M2: spine shims + RuntimeInitVmContext (#1056, #2126) - #2131

Merged
PurHur merged 1 commit into
masterfrom
agent/stdlib-ns2-spine-m3-1056
May 25, 2026
Merged

Self-host M2: spine shims + RuntimeInitVmContext (#1056, #2126)#2131
PurHur merged 1 commit into
masterfrom
agent/stdlib-ns2-spine-m3-1056

Conversation

@PurHur

@PurHur PurHur commented May 25, 2026

Copy link
Copy Markdown
Owner

Summary

  • Promote 3 deferred M2 spine inventory paths: literal src/yay-php8-compat.php plus spine-safe substitutes for src/llvm-env.php and src/macro_functions.php (no FFI/Yay macro link under LLVM 9 self-host).
  • Shrink $spineNativeLinkDeferred from 5 → 2 (bin/vm.php, lib/AOT/Linker.php only).
  • Extend native RuntimeInitVmContext::emit to allocate/wire VM\Context.errors and scriptStack alongside runtime / vmContext (M3 compile-driver batch toward Self-host M3: compile-driver real lowering symbol batch tracker #1768).

Test plan

  • php script/check-selfhost-spine-coverage-sync.php
  • php script/check-selfhost-spine-count-sync.php (609/611)
  • BOOTSTRAP_LIB_SPINE_SMOKE=1 make bootstrap-selfhost-lib-spine-smoke in php-compiler:22.04-dev
  • PHPUnit: RuntimeInitVmContextTest, SelfhostSpineSubstitutesTest, BootstrapSelfhostBundleTest

Closes #2126

Made with Cursor

…2126)

Promote yay-php8-compat and llvm-env/macro_functions spine substitutes so
deferred native-link paths shrink from 5 to 2 (bin/vm.php, AOT Linker).
Wire ErrorReporter and ScriptStack in native Runtime::initVmContext emit
for M3 compile-driver spine (#1768).

Closes #2126

Co-authored-by: Cursor <cursoragent@cursor.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.

Self-host M2: native-link 5 deferred spine inventory paths

1 participant