Skip to content

Perf: outperform JavaScriptCore across the verified benchmark matrix #44

Description

@chrisbbreuer

Goal

Reach and sustain higher zig-js throughput than the system JavaScriptCore on every workload and directly comparable execution mode in the repository benchmark matrix, without weakening semantics, checksums, GC safety, or no-GIL correctness.

Completed workstreams

Accepted completion baseline

The July 29, 2026 matrix measures clean runtime commit 14d94ec and is published by 018517d with all 1,540 raw samples:

  • Direct warmed context: 10/10 wins and 2.32x geometric-mean throughput.
  • Eight independent steady contexts: 10/10 wins, 2.53x throughput, and 5.35x scaling versus JSC 4.96x.
  • Eight independent cold lifecycles: 10/10 wins, 2.52x throughput, and 5.67x scaling versus JSC 4.97x.
  • Shared realm: every workload remains above 1.0x scaling at every lane; eight-lane geometric scaling is 4.84x.

Independent object churn now wins every directly comparable row:

  • steady 1/2/4/8 lanes: 106.180/116.422/145.601/207.214 ms versus JSC 134.892/139.490/156.091/208.272 ms;
  • cold 1/2/4/8 lanes: 109.688/117.079/135.536/216.272 ms versus JSC 137.150/143.667/155.324/220.921 ms.

Evidence: report, raw samples, and README scorecard.

Completion contract

  • Each engine executes identical workload and invocation bytes for directly compared rows.
  • Single-context and independent-context parallel modes compare equivalent programming models.
  • zig-js shared-realm results are reported separately unless a semantically equivalent public JSC mode is available.
  • Every timed row is long enough and sampled enough to report medians plus dispersion.
  • On the documented reference host, zig-js wins every direct and independent-context row.
  • Shared-realm no-GIL scaling has no workload below 1.0x at any reported lane count (Perf: remove shared-realm object-churn GC scaling collapse #97).
  • Accepted performance wins retain focused semantic, GC, no-GIL, full-unit, and TSan coverage.
  • The README and dated raw report were generated from a clean tracked worktree and reference the exact measured commit.
  • Controlled like-for-like history and generated README scorecard publication are complete (Perf: add benchmark regression gates and historical evidence #50).

Performance claims are scoped to the recorded workload matrix and host; they are not universal claims about arbitrary JavaScript applications.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions