
# Benchmarks

Performance is a release gate here, not a marketing page. Every number below is
generated at build time from the reports named in
`docs/acceptance/performance-report.json`, so this page cannot quietly pick up a
newer failed or incomplete run.

**MiB/s** is throughput, and higher is better. **p95** is the nearest-rank 95th
percentile of the retained samples, so it shows tail behavior rather than the
average. Hover or focus any table row for its budget, sample count, median, and
p95.

## Matched 1,000-file CLI comparison

ESLint, official Oxlint, and OXC for TSRX lint the same byte-identical TSX files, with one no-debugger rule, through each tool’s own npm entry point, over 5 warmups and 20 measured processes. The separate mixed-file-types row is a paired internal workload rather than a cross-tool comparison, and it is the only lane that enters the native TSRX path. Report: `benchmarks/comparative/results-1785296573160.json` (2026-07-29), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| OXC for TSRX / official Oxlint (matched TSX lane) | 1.165 × | ≤ 1.250 × | pass |
| ESLint / OXC for TSRX (matched TSX lane) | 13.235 × | ≥ 2 × | pass |
| Paired mixed-file-types / all-TSX product workload | 1.451 × | ≤ 1.500 × | pass |



## Native lint

Frozen release gate: throughput, same-build ordinary-path overhead, cold start, memory, and batch invariants. The npm-launcher ratio is a diagnostic boundary, not a speed claim. Report: `benchmarks/native-lint/results-1785296504890.json` (2026-07-29), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| P01 median standard-path latency ratio | 0.988 | ≤ 1.050 | pass |
| P01 p95 standard-path latency ratio | 0.965 | ≤ 1.080 | pass |
| P01 diagnostic parity | 1 | exactly 1 | pass |
| P01 direct standard bypass | 1 | exactly 1 | pass |
| P02 median scan+copy+parse throughput | 214.85 | ≥ 75 | pass |
| P02 p95 scan+copy+parse throughput | 187.82 | ≥ 60 | pass |
| P02 equivalent-TSX throughput ratio | 0.514 | ≥ 0.500 | pass |
| P02 warm 10 KiB p95 scan+copy+parse latency | 0.050 | ≤ 1 | pass |
| P03 in-process one-thread lint throughput | 108.58 | ≥ 35 | pass |
| P03 CLI one-thread lint throughput | 64.029 | ≥ 35 | pass |
| P03 end-to-end CLI latency ratio | 1.199 | ≤ 1.350 | pass |
| P03 diagnostic parity | 1 | exactly 1 | pass |
| P03 config compiled once | 1 | exactly 1 | pass |
| P03 config one parse per file | 1 | exactly 1 | pass |
| P03 configured rule applied | 1 | exactly 1 | pass |
| P05 fresh-process TSRX p95 latency | 4.807 | ≤ 50 | pass |
| Direct Rust / official Oxlint npm-launcher p95 ratio | 0.074 | ≤ 1.250 | pass |
| P05 startup-rule diagnostic parity | 1 | exactly 1 | pass |
| P07 TSRX peak RSS | 233422848 | ≤ 252723200 | pass |

**Near-threshold adjudication.** `P02 equivalent-TSX throughput ratio` entered the unchanged 3% band, so the aggregate required exactly 2 additional fresh identity-matched reports. Only triggering assertions receive two-of-three tolerance; every other assertion and invariant must pass in every report. The representative is selected by median normalized budget pressure with a stable report-path tie-break, never by choosing the fastest passing sample. Any failure more than 3% beyond its threshold, or a red selected representative, fails the aggregate. Retained reports: `benchmarks/native-lint/results-1785296491666.json`, `benchmarks/native-lint/results-1785296504890.json`, `benchmarks/native-lint/results-1785296517432.json`.

## Native format

Frozen release gate: formatter throughput, convergence scaling, memory, and batch invariants. The historical 16.6 MiB/s value is an absolute cross-corpus-derived floor, not a speedup claim. Report: `benchmarks/native-format/results-1785296526997.json` (2026-07-29), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| p04 direct median ratio | 0.988 | ≤ 1.050 | pass |
| p04 direct p95 ratio | 1.008 | ≤ 1.080 | pass |
| p04 direct output parity | 1 | exactly 1 | pass |
| p04 direct bypass | 1 | exactly 1 | pass |
| p04 sequential median mib s | 121.55 | ≥ 15 | pass |
| p04 sequential p95 mib s | 115.16 | ≥ 12 | pass |
| Sequential throughput vs absolute 16.6 MiB/s floor | 121.55 | ≥ 16.600 | pass |
| p04 default thread mib s | 450.74 | ≥ 100 | pass |
| p04 generalized control median mib s | 18.990 | ≥ 15 | pass |
| p04 generalized control p95 mib s | 16.615 | ≥ 12 | pass |
| p04 generalized control linear scaling | 1.016 | ≤ 1.350 | pass |
| p04 generalized control idempotent | 1 | exactly 1 | pass |
| p04 generalized control one parse | 1 | exactly 1 | pass |
| p04 generalized dynamic style coverage | 1 | exactly 1 | pass |
| p04 generalized style metadata | 1 | exactly 1 | pass |
| p04 generalized no hidden embedded parse | 1 | exactly 1 | pass |
| p04 idempotent | 1 | exactly 1 | pass |
| p04 one parse | 1 | exactly 1 | pass |
| p04 config compiled once | 1 | exactly 1 | pass |
| p04 config one parse per file | 1 | exactly 1 | pass |
| p04 config options applied | 1 | exactly 1 | pass |
| p05 stdin p95 ms | 3.454 | ≤ 110 | pass |
| Direct Rust / official Oxfmt npm-launcher p95 ratio | 0.039 | ≤ 1.250 | pass |
| p05 complete output | 1 | exactly 1 | pass |
| p07 rss ratio | 1.143 | ≤ 1.150 | pass |

**Near-threshold adjudication.** `p07_rss_ratio` entered the unchanged 3% band, so the aggregate required exactly 2 additional fresh identity-matched reports. Only triggering assertions receive two-of-three tolerance; every other assertion and invariant must pass in every report. The representative is selected by median normalized budget pressure with a stable report-path tie-break, never by choosing the fastest passing sample. Any failure more than 3% beyond its threshold, or a red selected representative, fails the aggregate. Retained reports: `benchmarks/native-format/results-1785296522210.json`, `benchmarks/native-format/results-1785296526997.json`, `benchmarks/native-format/results-1785296531837.json`.

## Opt-in type-aware lint

The opt-in TypeScript-Go lane. The default lane stays syntax-only with zero type processes. Report: `benchmarks/type-aware/results-1785296533520.json` (2026-07-29), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| Default syntax lint p95 | 2.556 ms | ≤ 10 ms | pass |
| Single-file type-aware p95 | 28.046 ms | ≤ 60 ms | pass |
| Two-file project type-aware p95 | 29.648 ms | ≤ 70 ms | pass |
| Single-file type-aware cold start | 58.416 ms | ≤ 100 ms | pass |
| Two-file project cold start | 27.921 ms | ≤ 120 ms | pass |
| Type-aware vs default p95 ratio | 10.972 × | ≤ 12 × | pass |
| Type processes per batch | 1 | exactly 1 | pass |
| Default path parse count per file | 1 | exactly 1 | pass |

## Vite/Vite+ command boundary

Fresh companion processes at the ecosystem seam. Vite build and HMR carry zero OXC for TSRX transforms. Report: `benchmarks/vite/results-1785296550669.json` (2026-07-29), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| Mixed companion lint p95 | 59.343 ms | ≤ 150 ms | pass |
| Mixed lint vs canonical p95 ratio | 1.698 × | ≤ 2.500 × | pass |
| Mixed companion format-check p95 | 132.80 ms | ≤ 220 ms | pass |
| Mixed format vs canonical p95 ratio | 1.192 × | ≤ 2 × | pass |
| Ordinary npm formatter p95 | 119.10 ms | ≤ 150 ms | pass |
| Ordinary npm formatter vs canonical p95 ratio | 1.069 × | ≤ 1.250 × | pass |
| Vite+ 0.2.4 mixed lint p95 | 254.57 ms | ≤ 750 ms | pass |
| Native TSRX parses per file | 1 | exactly 1 | pass |

## Native editor server

Syntax-only local language-server round trips on the retained Markless fixture. Report: `benchmarks/editor/results-1785296551322.json` (2026-07-29), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| Server start to first diagnostics | 2.696 ms | ≤ 50 ms | pass |
| Edit-to-diagnostics p95 | 0.128 ms | ≤ 25 ms | pass |
| Formatting p95 | 0.131 ms | ≤ 15 ms | pass |
| Safe code-action p95 | 0.118 ms | ≤ 25 ms | pass |
| RSS after 1,000-edit soak | 11.250 MiB | ≤ 96 MiB | pass |
| RSS growth through soak | 0 MiB | ≤ 8 MiB | pass |

## How a number gets on this page

Noise is handled by a fail-closed rerun policy rather than by picking a
favorable sample. A first report inside the 3% near-threshold band requires
exactly two additional fresh reports, and only the assertions that triggered get
two-of-three tolerance; everything else has to pass in all three. The
representative is chosen by median normalized budget pressure with a stable
report-path tie-break, never by taking the fastest run, and the aggregate fails
if the selected representative is red or if any failure lands more than 3%
beyond its threshold.

The harnesses are release-only, and `memory-stats` is linked into benchmark
executables only, never into the CLI you install. Make the authoritative release
decision with:

```sh
node tests/acceptance/run-performance.mjs
```
