Case study
Breath of the Wild: per-function matching decompilation of the Switch executable
Reimplements part of Breath of the Wild’s Switch v1.5.0 main executable in C++ and checks each function against the original machine code. The project calls itself a hybrid decompilation/reimplementation: it contains no assets, its ELF holds only reimplemented functions and cannot run the game, and porting is an explicit non-goal.
Requirements and limitations
- README calls this an experimental work-in-progress decompilation of Switch v1.5.0. The About page scopes it to the main executable (game code and most statically linked libraries), excluding RomFS assets, dynamically linked SDK libraries, libcurl, NEX and most of Havok. Functions are matched individually rather than placed at original addresses, so this is not a whole-executable matching build, a playable game or a port.
- Setup needs the user’s own main NSO executable from the Switch release. The pinned setup script verifies its hash, uses 1.5.0 directly and converts listed 1.6.0 or 1.9.0 executables to 1.5.0 with a project-hosted patch; RomFS and other game content are not used. The About page says the project is useless to anyone who does not own the game.
- The installation guide assumes Linux (native or WSL) or macOS and lists Python 3, Ninja, CMake, ccache, xdelta3, Clang and a Rust toolchain; the pinned CMakeLists requires CMake 3.30. Setup fetches Clang 4.0.1 for game code and installs tools/check. Submodules supply sead, agl, EventFlow, NintendoSDK headers and the shared nx-decomp-tools; the decompiling guide works from Hex-Rays or Ghidra output.
- tools/check diffs each listed function against the original executable, and data/uking_functions.csv records its status. At the pinned commit that list marks 32,079 of 113,490 functions matching, 514 non-matching, 7,601 work in progress, 6,270 library and 67,026 not decompiled; the mutable botw.link badges showed 17.493% by size and 30.398% by function on review. This collection did not run the checker.
- The pinned tree has no root license file and GitHub detects none, so no reuse license is stated; submodules and Nintendo content keep their own terms, and the About page calls the work a legal gray zone. AGENTS.md sets disclosure and human-review rules for AI-assisted contributions, but the reviewed files neither attribute the reconstruction to REA nor quantify AI use.
About this entry
- Type
- Case study
- Category
- Independent reconstruction cases
- Relationship
- Independent reconstruction project
- Targets
- Game
Sources reviewed
The description was reviewed against primary sources. This does not establish runtime testing, security auditing or verified compatibility.
Primary sources
- README.md GitHub · zeldaret/botw · Revision e78c024
- tools/setup.py GitHub · zeldaret/botw · Revision e78c024
- CMakeLists.txt GitHub · zeldaret/botw · Revision e78c024
- .gitmodules GitHub · zeldaret/botw · Revision e78c024
- tools/config.toml GitHub · zeldaret/botw · Revision e78c024
- data/uking_functions.csv GitHub · zeldaret/botw · Revision e78c024
- AGENTS.md GitHub · zeldaret/botw · Revision e78c024
- docs/about.mdx GitHub · open-ead/botw-decomp-www · Revision bafa219
- docs/contribute/installation.mdx GitHub · open-ead/botw-decomp-www · Revision bafa219
- docs/contribute/how-to-decompile.mdx GitHub · open-ead/botw-decomp-www · Revision bafa219
- viking/src/functions.rs GitHub · open-ead/nx-decomp-tools · Revision e0eae2f
- https://botw.link/progress