feat: GPU runner ported to Rust (anyxboxx_gpu_run.exe) #266

Merged
LooperSalty merged 7 commits from upstream-pr/266 into rust/full 2026-11-25 23:13:58 +00:00
LooperSalty commented 2026-11-25 22:42:21 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by LooperSalty on 2026-11-25T22:42:21Z.


Change

Port of runtime/gpu_runner (adapter.cpp, adapter.h, gpu_run.cpp: anyxboxx_gpu_run.exe, used by the RDNA 2 HLSL tests to run DXIL on a GPU or WARP and compare with the reference interpreter) to Rust, as part of the rust/full migration. Written by OpenAI Codex at the maintainer's request, in small commits on top of rust/full.

  • New crate for anyxboxx_gpu_run.exe (D3D12/DXGI through the windows crate): same command line, same output format and same error messages as the C++ runner, so tests/test_rdna2_hlsl*.py and PrototypeScarlett/emu/rdna2_gpu.py are unchanged.
  • Default adapter selection, named-adapter errors, empty pixel shaders and the Windows usage message encoding match the C++ runner.
  • CMake copy step next to the other Rust runtime pieces; the C++ runner stays as the parity oracle for now.
  • tests/test_rust_gpu_runner_parity.py: both runners on the same DXIL programs under WARP (ANYXBOXX_GPU=warp), outputs compared byte for byte, plus error cases.

Verification (local, Windows)

  • cargo build --release --workspace, cargo test --release --workspace, clippy (-D warnings), fmt, ruff: pass.
  • 43 WARP parity and HLSL tests pass with the Rust runner.
  • CMake/Ninja build and the copy of the Rust runner checked.
  • No game or game file was run or used.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LwHrL4bPjrVJiDKC8BDYfz

<!-- greyfinch-sync:LooperSalty/AnyXboxX:issue:6615248002 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/266). Originally posted by [LooperSalty](https://github.com/LooperSalty) on 2026-11-25T22:42:21Z. --- ## Change Port of `runtime/gpu_runner` (adapter.cpp, adapter.h, gpu_run.cpp: `anyxboxx_gpu_run.exe`, used by the RDNA 2 HLSL tests to run DXIL on a GPU or WARP and compare with the reference interpreter) to Rust, as part of the `rust/full` migration. Written by OpenAI Codex at the maintainer's request, in small commits on top of `rust/full`. - New crate for `anyxboxx_gpu_run.exe` (D3D12/DXGI through the `windows` crate): same command line, same output format and same error messages as the C++ runner, so `tests/test_rdna2_hlsl*.py` and `PrototypeScarlett/emu/rdna2_gpu.py` are unchanged. - Default adapter selection, named-adapter errors, empty pixel shaders and the Windows usage message encoding match the C++ runner. - CMake copy step next to the other Rust runtime pieces; the C++ runner stays as the parity oracle for now. - `tests/test_rust_gpu_runner_parity.py`: both runners on the same DXIL programs under WARP (`ANYXBOXX_GPU=warp`), outputs compared byte for byte, plus error cases. ## Verification (local, Windows) - `cargo build --release --workspace`, `cargo test --release --workspace`, clippy (`-D warnings`), fmt, ruff: pass. - 43 WARP parity and HLSL tests pass with the Rust runner. - CMake/Ninja build and the copy of the Rust runner checked. - No game or game file was run or used. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01LwHrL4bPjrVJiDKC8BDYfz
chatgpt-codex-connector[bot] commented 2026-11-25 22:42:34 +00:00 (Migrated from github.com)

Imported from LooperSalty/AnyXboxX. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T22:42:34Z.


Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-25T22:43:45.585140Z 15009cc PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

<!-- greyfinch-sync:LooperSalty/AnyXboxX:comment:7176694396 --> Imported from [LooperSalty/AnyXboxX](https://github.com/LooperSalty/AnyXboxX/pull/266#issuecomment-7176694396). Originally posted by [chatgpt-codex-connector[bot]](https://github.com/apps/chatgpt-codex-connector) on 2026-11-25T22:42:34Z. --- <!-- codex-pull-request-review-summary --> <!-- codex-review-state:v1 {"code_review":{"commit_sha":"15009cc279d92c12999c82bf68eccb22285456dd","has_any_findings":false,"has_unresolved_findings":false,"status":"completed"},"security_review":{"commit_sha":null,"has_any_findings":null,"has_unresolved_findings":null,"status":null}} --> <details> <summary><strong>Codex Review Summary</strong>: ✅ Completed</summary> This comment shows the latest Codex review activity on this pull request. | Review | Status | Commit | Review trigger | | --- | --- | --- | --- | | 📝 **Code Review** | ✅ **Completed** <relative-time datetime="2026-11-25T22:43:45.585140Z">2026-11-25T22:43:45.585140Z</relative-time> | `15009cc` | PR opened | <details> <summary>ℹ️ About Codex in GitHub</summary> <br/> [Your team has set up Codex to review pull requests in this repo](https://chatgpt.com/codex/cloud/settings/general). Reviews are triggered when you - Open a pull request for review - Mark a draft as ready - Comment "@codex review" or "@codex security review". Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. </details> </details>
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
LooperSalty/AnyXboxX!266
No description provided.