Warpspec – TLA+ model checking on a GPU, 4,600× faster than TLC

By hackernews · · Showcase

Warpspec – TLA+ model checking on a GPU, 4,600× faster than TLC

How compiling a TLA+ spec into fixed-size, bit-packed Rust took PaxosCommit from 4 hours 40 minutes in TLC to 3.65 seconds on an RTX 5090, with TLC

I’ve been looking for non-AI workloads where a single desktop GPU makes a big difference, and TLA+ model checking looked like a good fit. Checking a distributed protocol spec means walking through millions or billions of reachable states, and almost all of that work can run in parallel.

So I built warpspec to find out how fast a GPU could go. It compiles a TLA+ spec and its.cfg file into a fixed-size, bit-packed no_std Rust state machine, then searches the state graph on an NVIDIA GPU or on every core of a CPU. Both run the same generated code and print TLC-format counterexample traces when a check fails. It’s open source under Apache-2.0.

Speed doesn’t matter if the answers are wrong, so I held it to TLC’s numbers. On every model both checkers finish, warpspec reports the exact same distinct states, generated states, and search depth. Anything else is a bug.

CPU and GPU times are search time; TLC’s are its reported totals. I didn’t run TLC on the last two rows, and neither fits in RAM on the CPU checker. Full tables and verification notes are in docs/benchmarks.md.

What Hacker News is saying

  • “Bastard stole my idea!”
  • “Very cool idea, but maybe don't outsource both the implementation and the blog post to Claude?”
  • “This is very cool. I've wondered if something similar could be done to perform model checking on an FPGA.”
  • “Quite cool!…”

Read the full discussion on Hacker News →

Source: https://praveenperera.com/blog/tla-model-checking-4600x-faster-on-a-gpu/

More stories