Show HN: PS2 Games Statically Recompiled To WebAssembly
AIThis post was created with the assistance of artificial intelligence (AI).

TL;DR

Before you orderOffer from Amazon

Get the latest gadgets delivered free with Prime

  • Fast, free delivery on millions of items
  • Prime Video, Amazon Music and more included
  • Member-only deals all year
Start your free Prime trial Free trial for eligible customers · Cancel anytime
As an affiliate, we earn on qualifying purchases.

A GitHub project called ps2-web-recomp translates PlayStation 2 game code ahead of time into C++, then builds it into WebAssembly for browser play without a conventional emulator. Its author reports that Gran Turismo 4 and God of War II run in Chrome, but players must provide their own game disc images and results depend on hardware and settings.

A developer has published ps2-web-recomp, a project that translates PlayStation 2 game code into WebAssembly so selected titles can run in a browser without a conventional emulator, similar to a PSP game recompiled to WebAssembly. The project’s GitHub description reports that Gran Turismo 4 and God of War II reach playable sections in Chrome, using a reimplementation of PS2 hardware and operating-system functions.

The project takes a game’s Emotion Engine executable, analyzes its control flow and emits C++ code, which is then compiled to WebAssembly, a format also used by Firefox running in WebAssembly. A software layer recreates parts of the console’s operating system and hardware, while WebGPU handles graphics. The repository says the browser page reads the game disc image supplied by the user; it does not include game data.

According to the developer, Gran Turismo 4 runs from startup through its opening movie, menus and races, including music and sound effects. The PAL release ran at 50 frames per second in the recorded test, on a laptop’s integrated GPU in Chrome at twice the PS2’s resolution. The project also supports saving to a memory card stored in the browser.

The developer says God of War II was brought up using the same scripts, without game-specific code. Testing exposed two issues that Gran Turismo 4 had not: one in the recompiler and one involving vector-unit timing, along with missing parts of the PS2 input/output processor. The game reportedly runs from menus through cutscenes and into combat, at 60 frames per second in heavy combat at native resolution in Chrome. At twice native resolution, the reported rate ranges from 48 to 60 frames per second on the test laptop.

At a glance
announcementWhen: Reported in a Show HN post; current pro…
The developmentA developer has published a project that recompiles PS2 games for WebAssembly and reports playable browser builds of Gran Turismo 4 and God of War II.
Top Steam deals right now
Halo: The Master Chief Collection-75%$9.99
Red Dead Redemption 2-75%$14.99
Grand Theft Auto V Enhanced-56%$19.79
ARC Raiders-50%$19.99
Core Keeper-40%$11.99
Risk of Rain 2: Alloyed Collective-35%$9.74
Palworld-30%$20.99
Permafrost-20%$19.99
Live · Steam store (current discounts)

What Browser-Based Recompilation Enables

The project offers a different route to running older console software: rather than interpreting each instruction as the game runs, it translates executable code ahead of time and uses browser technologies for the resulting program. That approach can reduce the work required during gameplay, though the project still has to reproduce the PS2’s unusual processor behavior, graphics rules, sound and device interfaces closely enough for each title to function.

Its results also illustrate how demanding compatibility work extends beyond rendering. The developer describes modeling the PS2’s vector-unit timing and floating-point behavior, keeping the graphics system’s video memory layout, and implementing sound and movie playback. These details matter because games can depend on hardware behavior that differs from a modern computer, including how graphics data is reused and how calculations are rounded.

For readers, the practical result is a reported way to play certain PS2 titles in Chrome without installing a conventional emulator. It is not a hosted game service: users need their own disc image, and performance is tied to their browser and hardware. The project’s account is a developer report, not an independent performance test.

Amazon

PlayStation 2 game disc images

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

How the PS2 Code Runs

The repository describes this as a sibling project to psp-web-recomp, using a similar static-recompilation method. Its tool, eerecomp, divides translated code into units and preserves features of the PS2’s R5900 processor, including 128-bit registers and branch delay slots. The project implements the main processor’s operating-system services while running the game’s own I/O processor modules on an interpreter.

Graphics are handled through WebGPU compute shaders that aim to reproduce the PlayStation 2 Graphics Synthesizer’s rules for texturing, palettes, blending and depth. The page can render at one, two or three times the console’s native resolution. Vector-unit programs are compiled ahead of time when available or translated in the browser when first encountered. Audio and video are handled by software implementations of the PS2’s sound system and MPEG-2 decoder.

The developer’s performance account describes substantial optimization work. An early Gran Turismo 4 race ran at about 3 frames per second at native resolution with a software renderer and interpreted vector programs. Moving graphics work to WebGPU and compiling vector programs raised the reported rate to about 70 frames per second natively. Later changes reduced graphics command submissions and reused uploaded texture data; the repository says the latter cut data sent per frame by about 60 percent. At three times native resolution, the reported rate fell to 23 frames per second.

“No game data is included here. You bring a disc image of a game you own.”

— The ps2-web-recomp GitHub project description

Amazon

WebAssembly compatible gaming controllers

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Compatibility and Test Limits

The available account does not establish how many other games work, how consistently the two reported titles perform across different computers, or whether the project has been independently tested. The reported frame rates refer to specific Chrome tests on a laptop with an integrated GPU, and the description does not give the laptop model or a broader benchmark methodology.

The developer says vector-unit arithmetic can differ from the console in its last bit because the host performs the calculations, while the PS2 uses different rounding behavior. The account does not say whether this affects gameplay in either demonstrated title. It also does not set out the project’s legal guidance for creating or using disc images, beyond saying that game data is not included and users bring an image of a game they own.

The source description ends partway through a discussion of performance at three times native resolution. It therefore does not provide the full account of that optimization or establish how the project performs under that setting across games and devices.

Amazon

gaming laptop with integrated GPU

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

More Titles and Testing Needed

The immediate next step for readers is to inspect the repository and its short demonstration recording, then test the project with compatible hardware and a game image they are entitled to use. The project description does not announce a release schedule, a supported-game list, or a target date for further work.

Future updates could clarify compatibility beyond Gran Turismo 4 and God of War II, document browser and hardware requirements, and show whether reported performance holds on a wider range of systems. For now, the confirmed development is the published recompilation project and its author’s account of those two titles running in Chrome; broader support and independent verification remain open.

Amazon

browser-based game emulators

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Key Questions

What does the project do?

ps2-web-recomp translates PS2 game executable code into C++, compiles it to WebAssembly and supplies browser-based implementations of console functions, including graphics through WebGPU.

Which games have been reported working?

The project description reports playable progress in Gran Turismo 4 and God of War II. It does not provide a broader compatibility list.

Does the project include the games?

No. The repository says game data is not included; users provide a disc image of a game they own.

How fast do the games run?

In the developer’s Chrome test on a laptop with integrated graphics, Gran Turismo 4 reportedly ran at 50 frames per second at twice native resolution. God of War II reportedly ran at 60 frames per second at native resolution in heavy combat, and 48 to 60 at twice native resolution. These figures are project-reported results, not independent benchmarks.

Is this the same as a traditional emulator?

Not in the method described by its author. The project statically recompiles game code into WebAssembly and reimplements console functions, rather than relying on a conventional emulator to interpret the game as it runs.

Source: hn

HALLOWEEN

Halloween Picks

As an affiliate, we earn on qualifying purchases.

You May Also Like

Trade and supply-chain operations signal monitor: US-Iran talks to begin Sunday in Switzerland as Tehran closes the strait over Lebanon fi

Trade and supply-chain operations monitor signals indicate US-Iran negotiations begin Sunday, amid tensions over the Strait of Hormuz closure over Lebanon.

Game 1 Total Kills Prediction: Is It Going Over Or Under 65.5?

Analysis of the upcoming Dota 2 match between 1win and Team Nemesis, focusing on whether total kills in Game 1 will go over or under 65.5, with key details and uncertainties.

Fable, Opus 5.5, Astra, Sol And Luna: Which AI Model Is Worth Paying For?

Analysis of leading AI models—Fable, Astra, Sol, Luna, and Opus 5.5—comparing performance, costs, and suitability for different tasks as of September 2026.

Why AWS Continuum’s OpenAI Codex And Anthropic Claude Integration Matters For AI Safety

AWS Continuum has integrated with OpenAI Codex and Anthropic Claude Code, aiming to enhance AI coding security and governance—details are still emerging.