Case study
D2R Mobile: rehosting Diablo II: Resurrected’s Switch program on Apple devices
Runs the Nintendo Switch release’s own aarch64 program natively on iPhone, iPad and Apple silicon Macs, rewriting only instructions that depend on the Horizon kernel and supplying its system services and the NVN graphics API on Metal. Shaders are translated offline from the user’s files, and the project adds its own touch interface and endgame features. It is a rehosting compatibility layer, not a decompilation or recompiled source.
Requirements and limitations
- Targets only the Switch release with the Reign of the Warlock expansion at 1.0.34.0 (PC 3.3.94012); the rewrite rules stop on other versions. README reports iPhone/iPad builds for A14/M1 or later (iOS 26, or iOS 18–25 via an older-API build) and native Apple silicon Mac builds; A16-and-earlier devices need an extra texture pack, Apple TV is a community developer preview, and Intel Macs, A13-and-earlier chips and online play are unsupported.
- Supply your own Switch program files (ExeFS main, sdk and subsdk0) and RomFS update data for that version; the rewritten program, translated shaders and on-device resource folder are generated locally from them. The repository holds no game code, art, text or shaders, but records shader interface tables, graphics-API names and about 800 main-program addresses, itemized in docs/DERIVED.md.
- The main route is a full build on an Apple silicon Mac with Xcode, the Python environment that setup.sh prepares and an Apple signing account; a no-Xcode route packages a prebuilt shell on Windows, with Linux packaging and sideloading-tool signing reported unverified. Shader translation bundles Ryujinx’s translator, and SPIRV-Cross emits Metal source.
- dm/verify documents structural checks and Unicorn-based equivalence tests for every rewrite site, which need only the user’s files, plus unit tests. Save, tick-state and screenshot gates compare against ground-truth recordings from a patched Ryujinx; those recordings and driver scripts are not shipped, so these gates cannot be rerun from the repository. README reports a 44-device closed beta and dated iPhone 17 Pro Max measurements; this collection ran none of these checks.
- The project declares MIT; bundled third-party code keeps its own license (the Ryujinx translator MIT, deko3d-derived code zlib, FLIP BSD 3-Clause). Seven offline-play rewrites come from a community patch whose authorship and license are unknown. Blizzard and Nintendo retain their rights in the game; the reviewed sources establish no AI or REA attribution.
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 · jhaizhou-ops/d2r-mobile · Revision 9393b00
- dm/README.md GitHub · jhaizhou-ops/d2r-mobile · Revision 9393b00
- dm/verify/README.md GitHub · jhaizhou-ops/d2r-mobile · Revision 9393b00
- docs/GAME_FILES.md GitHub · jhaizhou-ops/d2r-mobile · Revision 9393b00
- docs/DERIVED.md GitHub · jhaizhou-ops/d2r-mobile · Revision 9393b00
- docs/DEPENDENCIES.md GitHub · jhaizhou-ops/d2r-mobile · Revision 9393b00
- LICENSE GitHub · jhaizhou-ops/d2r-mobile · Revision 9393b00