XS (xslang)
- title
- XS (xslang)
- type
- toolbox
- summary
- Language shipping compiler, JIT, LSP and full toolchain in one 2.9 MB binary across six backends
- tags
- language, cross-platform, jit, single-binary, watchlist
- language
- C
- license
- unknown (verify before relying)
- created
- 2026-05-21
- updated
- 2026-05-21
XS is a programming language whose pitch is a single 2.9 MB statically-linked binary that contains the compiler, language server, debugger, formatter, linter, test runner, profiler, and package manager โ and runs unchanged on Linux, macOS, Windows, WASI, iOS, Android, ESP32, and Raspberry Pi. Same source, six backends, three transpile targets, zero runtime dependencies, 132 KLOC of C source (excluding BearSSL).
What it claims
-
Six execution backends from one source:
xs --interpโ tree-walk interpreter for the REPL and AST-level plugin debugging.xs(default) โ bytecode VM, what normal runs go through.xs --jitโ register-allocating JIT for x86-64 and aarch64; opcodes outside its supported set fall back to the VM.xs --emit cโ C transpiler producing self-contained source for any reasonable C compiler.xs --emit jsโ JavaScript transpiler for Node or browser; ships less than the WASM build if you only need one program.xs.wasmโ WASM build of the compiler itself, with a virtual filesystem so any XS program can be evaluated at runtime in the browser.
-
Benchmarks (cold from disk, best of three, Linux x86-64):
- Startup hello-world: 3 ms.
- fib(30):
xs --jit31 ms, VM 138 ms, node 20 ~62 ms, cpython 3.13 ~71 ms.
-
Both installers (sh for macOS/Linux, irm pipe for Windows) verify the GitHub release against published SHA-256 sums before running.
Sample syntax
{- classic recursive fib, memoised -}
@memoize fn fib(n) {
if n < 2 { return n }
return fib(n - 1) + fib(n - 2)
}
println(fib(30)) -- 832040
Curly-brace, Haskell-style block comments {- ... -}, decorators (@memoize), expression-based if with implicit returns.
Why it's notable
The set of claims is unusual together. Cross-target single-binary languages exist (Tcl, embedded JavaScript engines), JIT'd dynamic languages exist (Lua/LuaJIT, V8, SpiderMonkey), language-server-in-the-compiler exists in modern designs (Zig, Crystal). Bundling the whole toolchain โ including the JIT and the LSP โ into one 2.9 MB binary that targets ESP32 and macOS is the part worth looking at.
The compiler being 132 KLOC of C is on the small side for this surface area. Comparison points: Lua is ~30 KLOC C, V8 is millions, the Zig compiler is ~250 KLOC of Zig.
Watchlist
Added to watchlist โ single-author project with limited public history at time of ingest. Things to re-check at the 90-day mark:
- Real-world adoption: does anyone outside the author ship code in this?
- Whether the iOS/Android/ESP32 claims hold up under scrutiny (mobile and microcontroller targets often imply ABI/runtime caveats).
- License posture โ the site doesn't make this obvious, and a "use everywhere" language without a clear license is a no-go for serious adoption.
Where it sits
Adjacent to ryelang-blog / rye-lang (small-binary embeddable language built around explicit capability whitelisting) and zig (the cross-platform-systems-language reference point). Each is making different choices about the cross-platform-plus-one-binary problem. XS bets on a much larger bundle (everything in one binary) than Rye does, and uses a more conventional syntax than Zig.
Site: xslang.org โ version 1.2.32 at ingest.