PS2Recomp

github.com/ran-j/PS2Recomp Mods & Fan Projects Open-source projectOpen source

PS2Recomp statically recompiles PlayStation 2 ELF binaries into C++ code and provides a runtime for native PC ports.

github.com/ran-j/PS2Recomp
PS2Recomp homepage screenshot

About PS2Recomp

PS2Recomp is an open source, experimental tool that statically recompiles PlayStation 2 ELF binaries into C++ code. It parses an ELF file to extract functions, symbols, and relocations, decodes the MIPS R5900 instructions in each function, translates them into equivalent C++, and generates a runtime that can execute the result. Each MIPS instruction maps to a single, literal C++ operation.

The project is split into modules: an analyzer that scans ELF functions and writes a TOML configuration, a recompiler that generates C++ output, a runtime that hosts memory, function registration, and syscall dispatch, and an IOP component for R3000A IRX execution. For retail or stripped games, the documented workflow starts by exporting a function map from Ghidra. The project requires CMake 3.20 or later and a C++20 compiler, and it has been tested mainly with MSVC. Some vector paths need SSE4 or AVX support on the host. Functions listed as skip are not recompiled and instead generate placeholder wrappers.

Key features

  • Translates MIPS R5900 instructions into C++ code
  • Supports PS2-specific MMI and VU0 macro instructions
  • Produces either single-file or multi-file C++ output
  • Configurable stubs, skips, and instruction patches through a TOML file
  • Analyzer module scans ELF functions and writes TOML configuration
  • Ghidra export script for function maps used with stripped games
Best for: Developers comfortable with C++20, CMake, and reverse engineering tools who want to study or port PS2 ELF binaries to native PC code.
Good for
  • Open source, with the source code and build instructions published in the repository
  • Generated C++ stays close to the original instructions, which makes the output easy to trace
  • Output generation has a low memory mode and configurable worker thread counts
Watch out for
  • Labeled as experimental in the project README
  • Currently tested mainly with MSVC
  • Some vector paths require SSE4 or AVX support on the host

PS2Recomp at a glance

Type
Open-source project
Pricing
Not confirmed. Check the site
Open source
Yes · Source code
Language
English
Last checked
Oct 6, 2026 · Online when checked
Listed
Oct 5, 2026

PS2Recomp alternatives

Tools and sites you could use instead, ranked by how closely they match.

All 24 alternatives

RetroReversing

retroreversing.com/source-code/decompiled-reta…

Study resources, tutorials, and tools for reverse engineering older video games.

BE

github.com/SIsilicon/WorldEdit-BE

Use a Bedrock Edition addon that ports WorldEdit functionality to Minecraft Bedrock.

Open source
24 alternatives

Shipwright

github.com/HarbourMasters/Shipwright

Shipwright ports Ocarina of Time using open source code and requires users to supply a supported game copy; it does not include copyrighted assets.

Popular in Mods & Fan Projects

Well-known listings from the same topic.

All 234

PS2Recomp FAQ

What is needed to build PS2Recomp?
The project requires CMake 3.20 or later and a C++20 compiler. The README gives build commands that clone the repository with submodules and run CMake configure and build steps.
How does the recommended workflow handle stripped games?
The README recommends opening the ELF in Ghidra, running the included ExportPS2Functions.java script, and using the exported TOML and CSV function map to recompile the game.
Is something wrong or out of date?

Tell us and an editor will check it.

Own this website?

Claim the listing and suggest updates yourself. An editor checks every claim first.

Claim this listing