PS2 Games Run in Browser via WebAssembly Recompilation
Original: Show HN: PS2 games statically recompiled to WebAssembly
Why This Matters
Static recompilation sidesteps emulation overhead, showing the web as a viable native-speed retro gaming platform.
Developer snuri00 has statically recompiled PS2 game machine code to WebAssembly, running titles like Gran Turismo 4 in-browser at full speed with no emulator, using WebGPU for rendering.
A new open-source project, ps2-web-recomp, translates PlayStation 2 Emotion Engine machine code directly into C++, compiles it to WebAssembly, and pairs it with a reimplemented PS2 OS and hardware layer that renders via WebGPU. No emulator is involved — it's static recompilation, not runtime interpretation.
The first title demonstrated is Gran Turismo 4, picked deliberately for its difficulty: it stresses both PS2 vector units, requires exact floating-point behavior for replays and license tests, and uses palette-from-framebuffer graphics tricks. The project runs it from boot through menus and races, with music, sound effects, and browser-based memory card saves.
On a laptop's integrated GPU in Chrome, the PAL release hits its native 50fps target at twice the original resolution. The project has 254 GitHub stars and 12 forks shortly after posting. It follows the same method as the developer's earlier psp-web-recomp project, which did the same for PSP titles. Source is MIT-licensed.