Theseus is a new Windows/x86 emulator that uses static binary translation instead of interpretation or JIT compilation. Rather than running x86 instructions dynamically, it translates the .exe into source code that an optimizing compiler then compiles natively. This approach leverages existing compiler infrastructure for optimization, enables native debugger integration, simplifies the emulator-to-host boundary, and allows partial evaluation of expensive runtime decisions at compile time. The post covers the tradeoffs versus JITs, why static binary translation is underused (technical challenges with dynamic control flow and cultural/legal issues), and future ideas like replacing parts of the translated program to work around Windows API quirks or improve performance.
Table of contents
Theseus, a static Windows emulatorWhat happened to retrowin32?Emulators and JITsStatic binary translationDecompilationAn old ideaBenefitsPartial evaluationWebAssemblyTheseusSort: