
# 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-1789846911273.json` (2026-09-19), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| OXC for TSRX / official Oxlint (matched TSX lane) | 1.206 × | ≤ 1.250 × | pass |
| ESLint / OXC for TSRX (matched TSX lane) | 13.177 × | ≥ 2 × | pass |
| Paired mixed-file-types / all-TSX product workload | 1.409 × | ≤ 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-1789846859997.json` (2026-09-19), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| P01 median standard-path latency ratio | 1.001 | ≤ 1.050 | pass |
| P01 p95 standard-path latency ratio | 1.005 | ≤ 1.080 | pass |
| P01 diagnostic parity | 1 | exactly 1 | pass |
| P01 direct standard bypass | 1 | exactly 1 | pass |
| P02 median scan+copy+parse throughput | 216.30 | ≥ 75 | pass |
| P02 p95 scan+copy+parse throughput | 201.43 | ≥ 60 | pass |
| P02 equivalent-TSX throughput ratio | 0.491 | ≥ 0.450 | pass |
| P02 warm 10 KiB p95 scan+copy+parse latency | 0.048 | ≤ 1 | pass |
| P03 in-process one-thread lint throughput | 110.39 | ≥ 35 | pass |
| P03 CLI one-thread lint throughput | 67.841 | ≥ 35 | pass |
| P03 end-to-end CLI latency ratio | 1.221 | ≤ 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 | 3.882 | ≤ 50 | pass |
| Direct Rust / official Oxlint npm-launcher p95 ratio | 0.108 | ≤ 1.250 | pass |
| P05 startup-rule diagnostic parity | 1 | exactly 1 | pass |
| P07 TSRX peak RSS | 231030784 | ≤ 250626048 | pass |



## 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-1789846871499.json` (2026-09-19), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| p04 direct median ratio | 1.211 | ≤ 1.250 | pass |
| p04 direct p95 ratio | 1.222 | ≤ 1.350 | pass |
| p04 direct output parity | 1 | exactly 1 | pass |
| p04 direct bypass | 1 | exactly 1 | pass |
| p04 sequential median mib s | 99.184 | ≥ 15 | pass |
| p04 sequential p95 mib s | 87.901 | ≥ 12 | pass |
| Sequential throughput vs absolute 16.6 MiB/s floor | 99.184 | ≥ 16.600 | pass |
| p04 default thread mib s | 322.35 | ≥ 100 | pass |
| p04 generalized control median mib s | 16.128 | ≥ 12 | pass |
| p04 generalized control p95 mib s | 14.897 | ≥ 10 | pass |
| p04 generalized control linear scaling | 1.009 | ≤ 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.364 | ≤ 110 | pass |
| Direct Rust / official Oxfmt npm-launcher p95 ratio | 0.101 | ≤ 1.250 | pass |
| p05 complete output | 1 | exactly 1 | pass |
| p07 rss ratio | 1.118 | ≤ 1.300 | pass |



## 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-1789846873134.json` (2026-09-19), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| Default syntax lint p95 | 3.449 ms | ≤ 10 ms | pass |
| Single-file type-aware p95 | 27.179 ms | ≤ 60 ms | pass |
| Two-file project type-aware p95 | 27.933 ms | ≤ 70 ms | pass |
| Single-file type-aware cold start | 69.869 ms | ≤ 100 ms | pass |
| Two-file project cold start | 27.410 ms | ≤ 120 ms | pass |
| Type-aware vs default p95 ratio | 7.880 × | ≤ 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-1789846886123.json` (2026-09-19), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| Mixed companion lint p95 | 65.685 ms | ≤ 150 ms | pass |
| Mixed lint vs canonical p95 ratio | 1.926 × | ≤ 2.500 × | pass |
| Mixed companion format-check p95 | 66.569 ms | ≤ 220 ms | pass |
| Mixed format vs canonical p95 ratio | 2.024 × | ≤ 2.100 × | pass |
| Ordinary npm formatter p95 | 36.928 ms | ≤ 150 ms | pass |
| Ordinary npm formatter vs canonical p95 ratio | 1.123 × | ≤ 1.250 × | pass |
| Vite+ 0.2.4 mixed lint p95 | 296.54 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-1789846886872.json` (2026-09-19), every budget passed.

| Boundary | Result | Budget | Status |
| --- | ---: | ---: | --- |
| Server start to first diagnostics | 3.857 ms | ≤ 50 ms | pass |
| Edit-to-diagnostics p95 | 0.169 ms | ≤ 25 ms | pass |
| Formatting p95 | 0.138 ms | ≤ 15 ms | pass |
| Safe code-action p95 | 0.155 ms | ≤ 25 ms | pass |
| RSS after 1,000-edit soak | 10.625 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
```
