feat(phase21.5): MirBuilder optimization prep + crate EXE infrastructure

Phase 21.5 optimization readiness - C-level performance target:
- MirBuilder: JsonFrag purify toggle (HAKO_MIR_BUILDER_JSONFRAG_PURIFY=1)
- Normalizer: extended f64 canonicalization + dedupe improvements
- loop_opts_adapter: JsonFrag path refinement for crate EXE compatibility

Infrastructure improvements:
- provider_registry: add diagnostics + ring-1 providers (array/console/map/path)
- mir_interpreter: add normalization/purify feature gates
- tools/selfhost_exe_stageb.sh: new end-to-end Stage-B→crate EXE pipeline
- tools/perf/microbench.sh: performance measurement tooling

Smoke tests (phase2100):
- Extend timeout 15s→120s for heavy crate EXE builds
- Add stageb_loop_jsonfrag_crate_exe_canary_vm.sh (target test)
- Add s3_backend_selector_crate_exe_vm_parity_return42_canary_vm.sh

Documentation:
- ENV_VARS.md: add Phase 21.5 optimization toggles
- README updates: clarify crate backend strategy
- phase215-optimization.md: new optimization roadmap

This commit sets the stage for Phase 21.5 critical optimization:
achieving C-level performance to decide hakorune's future viability.
This commit is contained in:
nyash-codex
2025-11-11 02:07:12 +09:00
parent ece91306b7
commit 07a254fc0d
49 changed files with 905 additions and 167 deletions

View File

@ -5,6 +5,6 @@ This directory hosts ring1 (core providers) and related documentation.
Goals
- Centralize provider responsibilities and selection policy.
- Keep ring1 minimal and reproducible (static or in-tree providers).
- Registry groups factories by Box type (e.g., "FileBox") to allow future expansion (Array/Map/Console/Path) without changing selection policy.
See also: src/providers/ring1/ and docs/architecture/RINGS.md

View File

@ -0,0 +1,6 @@
ring1/array — Placeholder (Scope/Policy)
- Purpose: future home for minimal, trusted ArrayBox providers (if introduced).
- Policy: ring1 is static/minimal only; no plugin (ring2) dependencies.
- Do not implement business logic here until design is finalized.

View File

@ -0,0 +1,6 @@
ring1/console — Placeholder (Scope/Policy)
- Purpose: future home for minimal, trusted Console providers (if introduced).
- Policy: ring1 is static/minimal only; no plugin (ring2) dependencies.
- Do not implement business logic here until design is finalized.

View File

@ -0,0 +1,6 @@
ring1/map — Placeholder (Scope/Policy)
- Purpose: future home for minimal, trusted MapBox providers (if introduced).
- Policy: ring1 is static/minimal only; no plugin (ring2) dependencies.
- Do not implement business logic here until design is finalized.

View File

@ -0,0 +1,6 @@
ring1/path — Placeholder (Scope/Policy)
- Purpose: future home for minimal, trusted PathBox providers (if introduced).
- Policy: ring1 is static/minimal only; no plugin (ring2) dependencies.
- Do not implement business logic here until design is finalized.