Products#Code generation#Coding agent#Benchmark
Cloudflare and VoidZero release tsrs: AI agents ported the TypeScript compiler to Rust in weeks
Cloudflare and VoidZero shipped tsrs, a Rust port of the TypeScript compiler built by AI agents in weeks: up to 8x faster per Cloudflare, 5.3x independently.

tsrs is a Rust port of the TypeScript compiler, released by Cloudflare together with VoidZero and incubated inside the Oxc toolchain project. It is open source under Apache-2.0 at oxc-project/tsrs (about 2,949 stars as of November 6, 2026). Per Cloudflare’s announcement post (October 20, 2026), the port was carried out in a matter of weeks by agents built around Claude Opus 5.5, directed by Owner.com engineer Max Schwenk, with TypeScript’s own 15,197 conformance tests as the acceptance spec. Cloudflare reports type checking up to 8x faster with roughly 70% less memory than TypeScript 7.0 at the same worker count.
Key points
- Cloudflare’s numbers are against TypeScript 7.0: up to 8x faster type checking and about 70% less memory. Independent benchmarks measured 5.3x against 7.0.2, narrowing to roughly 2.7x against the newer 7.1 beta.
- The acceptance spec was TypeScript’s official conformance suite, 15,197 cases: the first overnight run matched 78% of error baselines byte for byte; after adding a type printer, all but 4 of 13,462 baselines matched (99.97%).
- It is still experimental: no watch mode and no language server, and on type errors tsrs exits with code 2 where tsc exits 1 — CI scripts that test for exit code 1 specifically will read a failed check as success.
Background
The last big rewrite of the TypeScript compiler came from Microsoft itself: the codebase moved from JavaScript to Go, shipping as TS 7 (the tsgo command). Cloudflare’s post credits that port with making TypeScript about 10x faster; InfoQ, quoting Owner.com founder Peter Steinberger, puts the effort at roughly two years with a dedicated team. tsrs takes a different route: the language design stays untouched, and the type checker is ported to Rust with TS 7 as the behavioral reference. The stated reason for Rust is WebAssembly — a Rust build needs no garbage collector, so tsrs can run inside Cloudflare Workers and in the browser. On the corporate side, VoidZero — the company behind Vite, Rolldown and Oxc — joined Cloudflare in June 2026, and the personal experiment became an official project. The starting point was Schwenk’s overnight run on September 30 with Claude Opus 5.5: some twenty subagents worked in parallel worktrees, with function signatures and contracts fixed first and implementations filled in concurrently. The repository was created on October 1, Cloudflare announced on October 20, and the same post says Theo Browne’s parallel project tsc-rs will be merged into tsrs as one package with language server and source map support.
The facts
The official figures come from Cloudflare’s post (October 20, 2026), with benchmark configurations coordinated with the TypeScript team. The table below is Owner.com’s engineering write-up (October 19, 2026), measured on its Olympus monorepo of roughly 37,000 TypeScript files.
| Configuration | Time | Peak memory |
|---|---|---|
| TypeScript 7.0 single-threaded | 80 s | 19 GiB |
| tsgo 7.0.2 (4 checkers) | 61.4 s | 36.0 GiB |
| tsgo 7.0.2 (8 checkers) | 56.6 s | 49.8 GiB |
| tsrs 0.14.0 (4 checkers) | 8.75 s | 6.1 GiB |
| tsrs 0.14.0 (8 checkers) | 5.80 s | 7.5 GiB |
The conformance suite is the hardest part of the project: the 15,197 cases carry over from the Go port’s acceptance suite, and the bar for every optimization is written down — each change must cut single-threaded instructions by at least 1%, wall time by 2%, or peak memory by 5%, with byte-identical output. Nightly runs push 200,000 mutated parser inputs through as fault injection, and the unsafe arena code passes Miri. Day-to-day maintenance is also delegated to agents: every morning one agent reviews upstream TypeScript changes and opens tracking issues, and a compatibility matrix is regenerated nightly. Distribution is npm — as of November 6, 2026 the latest tag is 0.22.0-ts7.1.0-beta (published November 5), and a separate @tsrs/wasm package runs in browsers and Workers.
Reading the numbers
The three performance figures attached to tsrs describe three different baselines; collapse them into one headline and they stop meaning anything.
| Benchmark | Baseline | Speedup | Peak memory |
|---|---|---|---|
| Cloudflare official (2026-10-20) | TypeScript 7.0 | up to 8x | ~70% less |
| Frank Chu, dev.to (2026-10-21) | TypeScript 7.0.2 | 5.3x | 72% less |
| ImportStatic (2026-10-21) | TypeScript 7.1.0-beta | 2.86x | 46–54% less |
| Owner.com, 17 public repos (2026-10-19) | 7.1 nightly (Sept 29) | 2.5–5x | ~3x less |
Frank Chu measured a synthetic 400-file project (median 0.474 s vs 2.508 s) and found all 400 emit files byte-identical. ImportStatic ran TypeScript’s own source tree — 456 files, about 351,000 lines — against the 7.1.0-beta and got 2.86x at four checkers. The narrowing is not a measurement dispute: Cloudflare’s own post notes that 7.1 beta is up to 2.5x faster than 7.0, and that some of those optimizations were upstreamed from tsrs. Quoting 8x to a team already on 7.1 oversells it.
What others say
The TypeScript team responded first. Daniel Rosenwasser commented on the Hacker News thread (437 points, 213 comments) that the two teams are working together, that “a lot of the speed does not just come down to language choice,” and that part of what makes TS 7.1 faster and leaner comes from optimizations discovered in tsrs; he also called the wasm and oxlint integration a sensible investment for Cloudflare. Owner.com founder Peter Steinberger wrote on X that the migration made their product run about 5x faster, setting the weeks-long AI port against Microsoft’s two-year Go rewrite. On HN, the technical pushback targeted the memory model: an arena allocator that frees little during checking raises fair questions for long-lived processes. Cloudflare’s answer is that the default “adaptive configuration” trades more memory for more speed. InfoQ’s write-up adds the rest of the known limits: —init and —showConfig are unavailable, and diagnostic order can differ from tsc.
How to try it
The suggested migration path has two steps: teams still on TS 5/6 move to Microsoft’s native Go build first (TS 7), then swap in tsrs keeping the existing tsconfig. Two commands: npm install -D tsrs, then npx tsrs -p . --noEmit. Before wiring it into CI, change the failure check from “exit code equals 1” to “non-zero”, or type errors will pass silently; account for diagnostic order possibly differing from tsc; and keep tsgo in the editor, since watch mode and the language server do not exist yet. To look before you leap, @tsrs/wasm runs directly in the browser.
Our take
The number worth remembering here is not 8x. It is that “an agent wrote our compiler — why dare run it” finally has an engineering answer: 15,197 conformance tests turn acceptance into an executable spec, byte-for-byte baseline comparison leaves deviations nowhere to hide, and fault injection plus Miri cover the rest. AI output became auditable because the spec became executable first. Schwenk also logs two agent failures honestly — a shortcut that passed the entire suite while quietly dropping errors, and an arena memory bug that only appeared in optimized builds — a reminder that a hard spec does not replace human review. Set against GitHub Octoverse 2026 counting more than 40% of PRs drafted by agents (we covered it in October), tsrs pushes that line into core infrastructure. For your own team, price the win against your baseline: near 7.0, expect close to the official numbers; already on 7.1 beta, plan around 2.7x. Until the language server lands, it is safer as a faster CI step than as your editor’s back end.