The Spectrum Dispatch News

technology

Shitty: A new fast terminal emulator built with Vulkan and Metal

A memory-unsafe terminal written in C++23 prioritizes speed and startup time, outperforming established alternatives in throughput benchmarks.

Shitty: A new fast terminal emulator built with Vulkan and Metal

Shitty is a new terminal emulator designed for low latency, fast startup, and predictable resource use. The project, available on GitHub, uses native compute backends—Vulkan on Linux and Metal on macOS—to render terminal cells while keeping terminal state on the CPU.

Shitty: A new fast terminal emulator built with Vulkan and Metal

According to benchmarks included in the repository, Shitty demonstrates faster throughput than competing terminals when processing data through the GUI. In tests on an Apple-silicon MacBook printing 100MB of ASCII characters through an 80x24 grid with 500 lines of scrollback, Shitty achieved 0.81 seconds wall time with approximately 118 MiB/s throughput, compared to Alacritty’s 0.96 seconds and ~99 MiB/s, Kitty’s 1.28 seconds and ~75 MiB/s, and Ghostty’s 1.49 seconds and ~64 MiB/s.

When processing random bytes (the parser’s worst case with invalid UTF-8), Shitty completed in 1.88 seconds at ~51 MiB/s, faster than Alacritty at 3.07 seconds (~31 MiB/s) and Ghostty at 4.63 seconds (~21 MiB/s). Kitty did not complete this test, instead reacting to embedded escape sequences with title changes and bells rather than drawing.

The terminal includes comprehensive feature support: VT52 through VT5xx controls, primary and alternate screens, rectangular operations, synchronized output, and reflow of scrollback when terminal width changes. It handles Unicode grapheme clusters, emoji sequences, combining characters, and CJK double-width characters. Color support ranges from 16-colour to 24-bit, with extended underline styles.

Shitty is written in C++23 and built with Clang. The project emphasizes correctness, incorporating more than 5,000 tests harvested from over a dozen test suites including kitty, xterm’s vttests, and libvterm, all driven through a real PTY. The parser state machine is fuzzed with committed corpora to ensure robustness. The terminal is self-contained—a single small binary with embedded fonts that starts on machines with no fonts installed.

Security features include being locked down by default; applications cannot read selections or drive the host window unless explicitly allowed. The terminal uses UTF-8 internally and exports TERM=xterm-256color to child processes.

Installation is available via Homebrew for macOS (brew install pg83/tap/shitty), with portable binaries attached to GitHub releases. A Nix flake is also provided for development and system integration.

Key facts

  • Shitty achieved ~118 MiB/s throughput processing ASCII, faster than Alacritty (~99 MiB/s), Kitty (~75 MiB/s), and Ghostty (~64 MiB/s)
  • The terminal includes over 5,000 tests harvested from a dozen conformance test suites
  • Written in C++23, uses Vulkan on Linux and Metal on macOS for rendering
  • Self-contained binary with embedded fonts, no windowing toolkit dependency
  • Supports Unicode grapheme clusters, emoji sequences, combining marks, and CJK characters

Sources

← All posts