XC2 NS2 Recomp
XC2 NS2 Recomp is a Windows PC port of Xenoblade Chronicles 2 that runs at 59-60 fps and supports 4K cutscenes.
- Type: PC port
- Game: Xenoblade Chronicles 2
- Runs on Windows
- By weile10000
- Latest release v0.1.4, 2026-11-20
- Source: https://github.com/weile10000/xc2-ns2-recomp
README
Xenoblade Chronicles 2 · Nintendo Switch 2 Edition — static recompilation (PC)
Ahead-of-time ("static") recompilation of the retail Xenoblade Chronicles 2 – Nintendo Switch 2 Edition
(title id 0100E95004038000, game version 3.0.1) running on Windows x86-64 through Vulkan.
The game's NSO modules are lifted to C++ by nxrecomp and linked against a small Switch runtime (third_party/fefw-recomp) whose NVN implementation replays the game's graphics API on Vulkan. Shaders are translated from Maxwell / Ampere SASS to SPIR-V by Ryujinx's translator, driven by our offline harness.
This repository contains no game code and no game assets. It is the toolchain, the runtime and the project's documentation. You need your own legally acquired copy of the game — see What you must supply below.
Status (2026-11-18)
| Boot | ✔ reaches the title screen, loads a 2022 clear save, plays in the field |
| Frame rate | 59–60 fps in the port and most areas (1080p, 1440p or 4K alike); 43–52 fps in the open plain, the heaviest area; 1% low ≈ 51 |
| Graphics | NVN 3.5 replay on Vulkan; Maxwell shaders translated offline; Ampere (Switch 2) shaders translated from SASS |
| Upscaling | the game's DLSS/NDSR slot is served by the built-in TAAU by default; FSR 4.1.2 and FSR 3.1.6 are selectable at run time ([dlss] upscaler = fsr3) |
| Audio | Opus (software decoder) + nn::audio OutputStream on the host sink |
| Movies | 4K cutscenes play (AV1 3840×2160, 30 fps) with lip sync; the retail build's BGM, effects and voices come out through a host XAudio2 sink |
| Input | keyboard/mouse and gamepad |
Known issues
- A blue-grey rim around characters and other objects where they meet the cloud sea. Measured to live inside the game's 640×360 volumetric-fog layer (the in-scatter ramp across the depth step); the platform-level suspects (depth filtering, shadow-map compare, texture gather rounding, upscalers) were each tested and excluded, so the fix has to be inside the game's own fog pass.
- Residual shimmer in the cloud sea in-game (the game dithers its volumetric fog at 640×360; the console leans on its neural upscaler).
- Slow frames on area transitions are dominated by texture uploads and guest/host lock waits.
- A 4K cutscene waits while the game is still loading: 1–20 s of stalls at the start of a CG, and an occasional audio drop in that window. The film is fine once the game has finished loading.
- The first cutscene frame can flash green for a moment on some runs.
Something went wrong?
Report it from the launcher: About → Record a report, or Play → Record a report right after a run that ended
badly. It plays the game once more with the diagnostics on and writes work\reports\report-<stamp>.zip when you
close the window; attach that zip to the issue. It holds the log, your settings and your driver's capability lines,
and nothing in it is game data — which is why a report with the zip is worth ten without one.
What you must supply
The recompiler needs the game's own files; they are never part of this repository and are never downloaded:
| what | where it goes (default) |
|---|---|
ExeFS of the 3.0.1 program: main, sdk, subsdk0, subsdk1, subsdk2, subsdk3, rtld, main.npdm | xc2/game/xc2ns301/ |
the 3.0.1 romfs (bf2.ard, bf2.arh, stream/) | referenced by NXRT_FS_ROMFS at run time |
| add-on content (optional) | referenced by NXRT_AOC_DIR |
The built executable embeds the lifted game code, so builds are not distributed: build it locally from
your own dump (see docs/BUILD.md).
How it works
ExeFS (NSO) ──nxrecomp lift──▶ C++ ──clang-cl──▶ main.lib ──┐
├──▶ xc2_boot.exe
runtime (fefw-recomp: NVN/NVN2, hid, fs, audio, kernel) ────┘
│
└─ NVN calls ──▶ Vulkan replay ──▶ SPIR-V shaders (offline harness, Ryujinx translator)
The runtime is a general Switch/NVN service layer (not XC2-specific); everything game-specific lives in this repository: the lift sites, the boot glue, the launcher, and the analysis tools.
Build
See docs/BUILD.md. In short: a Windows toolchain (MSVC + LLVM clang-cl, .NET 10 SDK, Vulkan SDK, Python 3.12), then
# once, after placing your 3.0.1 ExeFS in xc2\game\xc2ns301\
.\tools\build\build.ps1 -Exefs xc2\game\xc2ns301 -Run:$false `
-Modules 'main,sdk,subsdk0,subsdk1,subsdk2,subsdk3,rtld' `
-LiftDir xc2\build\301\lift -ObjDir xc2\build\301\obj -LibDir xc2\build\301\lib
.\tools\build\build-boot.ps1 -Exefs xc2\game\xc2ns301 -OutDir xc2\build\301\boot `
-LibDir xc2\build\301\lib -MainLib xc2\build\301\lib\main.lib -Defines XC2_MODULES_7
Documentation
- docs/QUICKSTART.md — ten minutes from a clean clone to the title screen
- docs/ARCHITECTURE.md — how the lift, the runtime and the shader pipeline fit together
- docs/COMPATIBILITY.md — what runs, what does not, and the measured frame rate
- docs/TROUBLESHOOTING.md — symptom first: black screen, driver crashes, wrong frame rate
- docs/INVARIANTS.md — the three rules the project holds itself to
- CONTRIBUTING.md — reporting a problem, building, opening a pull request
- CHANGELOG.md — dated milestones
docs/reports/— the lift and NVN service reports- The §-numbered working notes (one file per round, with every experiment and dead end) are kept outside this
repository. Code comments and the reports refer to them as
HANDOVER Nor§N: those numbers are kept so the code and the notes stay cross-referenced, but the notes themselves are not published. - docs/MODS.md — the mod interface: folder layout, order, conflicts, code patches (draft)
docs/ENVIRONMENT.md— toolchain, Python packages, build entries, data layouttools/README.md— the analysis and run tools
Credits
- nxrecomp — the static recompiler used to lift the game
- Goldoire/fefw-recomp — the Switch runtime this project is built on,
and the reason it exists at all: the NVN/NVN2 replay layer, the service HLE, the shader pipeline and the
exe+DLL packaging split all started there. Our fork lives in third_party/fefw-recomp
and every change to it is listed in its
MODIFICATIONS.md. - Ryujinx (MIT) — the Maxwell shader translator used by the offline shader harness
- SDL3, Vulkan-Headers, VMA, and the other vendored dependencies (see THIRD_PARTY_NOTICES.md)
- AksharDP/xc2-recomp and the Lichii PRs — read for reference findings, no code copied
- DeepSeek V4.1 Flash (build 1017, @deepseek) — pair-programmed this project with its author, from the first lift to this release: the runtime work, the replay optimisation, the documentation and the review rounds
- @capibawa — nxnative, branch
xc2-ns2-profile: the launch switches and the host-side movie/audio takeover that this project's film path follows
Licence
The project's own code is GPL-3.0-or-later — LICENSE carries the GPL-3.0 text and the "or later" is
this project's choice. Third-party components keep their own licences, listed in
THIRD_PARTY_NOTICES.md and in third_party/fefw-recomp/MODIFICATIONS.md. No licence
here grants any right to Nintendo's game. The lifted code the build produces from your own dump is not covered by
this licence, is not distributed, and remains the property of its rights holders.
Legal notice
This is an independent, non-commercial fan project. It is not affiliated with, sponsored by, or endorsed by Nintendo. Xenoblade Chronicles, Xenoblade Chronicles 2, Nintendo Switch and Nintendo Switch 2 are trademarks of Nintendo; Xenoblade Chronicles 2 was developed by MONOLITH SOFT. This repository contains no game code, no game assets and no keys, and gives no help in obtaining them.
本项目是独立的非商业粉丝项目,与任天堂没有任何关联,也未获得任天堂的认可。《异度之刃 2》、Nintendo Switch 与 Nintendo Switch 2 是任天堂的商标;《异度之刃 2》由 MONOLITH SOFT 开发。仓库中不含任何游戏代码、游戏资源或密钥, 也不提供任何获取途径。
中文说明
本项目是《异度之刃 2(Nintendo Switch 2 Edition)》3.0.1 零售版的静态重编译(PC / Windows + Vulkan): 把游戏的 NSO 模块整体举升成 C++,再链接一个通用 Switch 运行时(自己实现的 NVN → Vulkan 重放层)运行。
- 仓库里没有任何游戏代码、游戏资源或密钥;需要你自己的游戏 dump(路径见上表),构建产物(含举升后的游戏代码) 不随仓库分发,只能本地构建。
- 当前状态:能启动、读 2022 通关存档、进游戏;港口与多数区域 59–60 fps,大平原 43–52 fps,4K 输出几乎零成本;
4K 过场 CG 30fps 正常播放、音画同步。已知问题见
docs/COMPATIBILITY.md。 - 遇到问题请从启动器提交:关于 → 录制一份报告,或者游戏异常退出后在 开始游戏 页点「录一份报告」。
它会用诊断模式再跑一次游戏,关掉窗口时把日志、设置、驱动能力行打包到
work\reports\report-<时间>.zip, 把这个 zip 附在 issue 里即可;里面没有任何游戏数据。带日志的问题几乎都能查,没有日志的大多只能猜。 - 构建方法见
docs/BUILD.md;工具链见docs/ENVIRONMENT.md;架构见docs/ARCHITECTURE.md。 - 影片/音频的宿主接管思路来自 @capibawa 的 nxnative(
xc2-ns2-profile分支)。 - 本项目的运行时来自 Goldoire 的 fefw-recomp:NVN/NVN2 重放层、
服务层 HLE、着色器管线、exe + DLL 的打包形态都奠基其上。没有那个项目,就没有这次重编译。我们的分支在
third_party/fefw-recomp,改动逐条记在它的MODIFICATIONS.md。