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
Make zig-js broadly faster than JavaScriptCore on representative JavaScript and WebAssembly workloads—not merely the current ten-kernel matrix—while preserving exact ECMAScript/WebAssembly semantics, precise/moving-GC safety, GIL-free correctness, bounded resources, and reproducible evidence.
This is the successor performance roadmap to completed #44. It does not reopen or diminish #44: the July 29 matrix already records 10/10 zig-js wins in all directly comparable modes. It expands the target to the performance surfaces that the current matrix does not cover and to the measured gaps that remain.
Current evidence boundary
Already green
The accepted clean-tree publication at 018517d2 measures runtime 14d94ec0:
direct warmed context: 10/10 wins, 2.32x geometric-mean throughput;
Wasm SIMD is only 0.10–0.14x JSC throughput at eight independent contexts because fixed-width SIMD currently executes through the portable interpreter rather than native vector instructions: report.
Shared object churn reaches only 1.48x eight-lane scaling in the latest accepted matrix, far below the near-linear compute rows.
Moving age-three GC is 0.63x its non-moving parent on high-survival work and 0.80x on shared mixed-survival work; shared moving pauses reach 110.56 ms with bounded rendezvous retries: report.
A no-GIL shape-mutation witness records 271,244 optimizer publications and 271,244 invalidations versus 40 publications and zero invalidations serialized, because Class-A invalidation is owner-wide.
Native optimizer publication is declared only on macOS AArch64. macOS x86-64 and Linux remain baseline/bytecode fallbacks.
The VM flat-slot model cannot represent block shadowing, TDZ, or per-iteration captured bindings, so substantial correct JavaScript never reaches bytecode or native tiers.
The comparison matrix does not cover strings, RegExp, JSON, Maps/Sets, typed arrays, promises/async, modules, classes, iterators, Intl, Temporal, proxy/accessor-heavy objects, large application graphs, warmup cost, code size, or memory efficiency.
Non-negotiable engineering contract
Owned dependency boundary. Production engine/package dependencies may only be zig-utils-owned sibling checkouts under ~/Code/** (currently ../zig-regex and ../zig-gc). Do not add a network package, vendored third-party runtime, system JS engine, C/C++ engine, or opaque binary dependency. External standards corpora and system JSC remain pinned, test/benchmark-only oracles, never library dependencies.
No workarounds. No source/function/benchmark recognition; no checksum shortcuts; no disabled safety/GC/barrier/checkpoint behavior; no benchmark-only tier selection; no silent fallback described as completion; no permanent suppressions; no threshold-only change presented as a root-cause fix; no unbounded cache/pool/reserve used to buy a score.
Causal evidence. Retained optimizations need exact-parent A/B evidence, profile attribution, identical work/checksums, memory/RSS accounting, and focused semantic/TSan gates. Rejected candidates stay documented and reverted.
No universal claims from microbenchmarks. Workload-scoped evidence remains explicit. Broader claims require broader representative matrices.
Portable correctness. Unsupported native backends must fail closed to exact lower tiers until they have the same differential, GC, sanitizer, and performance evidence as macOS AArch64.
Roadmap structure
Child issues are grouped into:
performance evidence and anti-regression infrastructure;
dependency sovereignty and owned tooling;
bytecode, baseline JIT, optimizer, object model, and built-in hot paths;
GC, allocation, shared-realm scaling, startup, and memory;
WebAssembly native execution and SIMD/threads;
backend portability and cross-tier differential verification.
An issue may start early for investigation/instrumentation, but it must not publish a performance completion result before its declared predecessors provide the required contract/evidence.
Program-level completion gate
Every child is complete with its own causal evidence and correctness gates.
The expanded representative matrix is fully defined before “win all benchmarks” is evaluated.
Goal
Make zig-js broadly faster than JavaScriptCore on representative JavaScript and WebAssembly workloads—not merely the current ten-kernel matrix—while preserving exact ECMAScript/WebAssembly semantics, precise/moving-GC safety, GIL-free correctness, bounded resources, and reproducible evidence.
This is the successor performance roadmap to completed #44. It does not reopen or diminish #44: the July 29 matrix already records 10/10 zig-js wins in all directly comparable modes. It expands the target to the performance surfaces that the current matrix does not cover and to the measured gaps that remain.
Current evidence boundary
Already green
The accepted clean-tree publication at 018517d2 measures runtime 14d94ec0:
Evidence: report and 1,540 raw samples.
Measured gaps
Non-negotiable engineering contract
~/Code/**(currently../zig-regexand../zig-gc). Do not add a network package, vendored third-party runtime, system JS engine, C/C++ engine, or opaque binary dependency. External standards corpora and system JSC remain pinned, test/benchmark-only oracles, never library dependencies.Roadmap structure
Child issues are grouped into:
Child issue map
Evidence and owned dependencies
libffiwith an owned native ABI dispatcherJavaScript frontend and execution tiers
GC, memory, startup, and concurrency
Native backends
WebAssembly
Cross-cutting release gates
Recommended execution order
An issue may start early for investigation/instrumentation, but it must not publish a performance completion result before its declared predecessors provide the required contract/evidence.
Program-level completion gate
Related completed foundations
#44, #49, #52, #97, #132, #133, #144, #145, #146, #283, #426, #431, #432, #433, #434, #437, #438, #439, #440, #445, #446, #447, #448, #450, #451, #452.