Tests: add disassembly verification for v_madak_f32 Xbox extension #1457

Open
Ayoub-devv wants to merge 1 commit from upstream-pr/1467 into main
Ayoub-devv commented 2026-11-24 16:33:55 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Ayoub-devv on 2026-11-24T16:33:55Z.


What is in it

  • crates/xcl/src/gpu/rdna2.rs: add one #[test] (console_madak_f32_disassembles) that decodes a fixed byte encoding of the Xbox console extension v_madak_f32 (opcode 0x21, ENC_VOP2, MADAK format) and asserts the disassembly string. No runtime code is changed; the test lives inside the existing #[cfg(test)] mod tests.

Tested

  • Windows x64, CPU-only (no GPU / no game data / no XCL_SAMPLE_* required)
  • cargo test -p xcl --lib console_madak_f32_disassembles: 1 passed, 0 failed
  • A pre-existing fetch_update deprecation warning from xgameruntime/mod.rs was emitted; unrelated to this diff.

Regression run

  • Not needed — test-only change inside #[cfg(test)]; optimal_mode/disassembler runtime code is unmodified.

Not tested

  • GPU paths and retail titles (not reachable from this CPU-only string test).

AI use

  • GitHub Copilot agent (frontier model, GPT-6) wrote the test directly into the file from a spec prompt; I reviewed the bytes, the opcode, and the asserted string by hand before running.
<!-- greyfinch-sync:ivall/xcl:issue:5476262074 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1467). Originally posted by [Ayoub-devv](https://github.com/Ayoub-devv) on 2026-11-24T16:33:55Z. --- **What is in it** - `crates/xcl/src/gpu/rdna2.rs`: add one `#[test]` (`console_madak_f32_disassembles`) that decodes a fixed byte encoding of the Xbox console extension `v_madak_f32` (opcode 0x21, ENC_VOP2, MADAK format) and asserts the disassembly string. No runtime code is changed; the test lives inside the existing `#[cfg(test)] mod tests`. **Tested** - Windows x64, CPU-only (no GPU / no game data / no `XCL_SAMPLE_*` required) - `cargo test -p xcl --lib console_madak_f32_disassembles`: 1 passed, 0 failed - A pre-existing `fetch_update` deprecation warning from `xgameruntime/mod.rs` was emitted; unrelated to this diff. **Regression run** - Not needed — test-only change inside `#[cfg(test)]`; `optimal_mode`/disassembler runtime code is unmodified. **Not tested** - GPU paths and retail titles (not reachable from this CPU-only string test). **AI use** - GitHub Copilot agent (frontier model, GPT-6) wrote the test directly into the file from a spec prompt; I reviewed the bytes, the opcode, and the asserted string by hand before running.
copilot-pull-request-reviewer[bot] commented 2026-11-24 16:34:11 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by copilot-pull-request-reviewer[bot] on 2026-11-24T16:34:11Z.

Review: COMMENTED


Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

<!-- greyfinch-sync:ivall/xcl:review:6043344422 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1467#pullrequestreview-6043344422). Originally posted by [copilot-pull-request-reviewer[bot]](https://github.com/apps/copilot-pull-request-reviewer) on 2026-11-24T16:34:11Z. **Review:** COMMENTED --- Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.
futurepro62 commented 2026-11-24 17:06:48 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by futurepro62 on 2026-11-24T16:57:19Z.


Full-suite run, since this PR has no test report yet. Tested exact head 0293e77 (on its base b7aa9f3).

Tested

  • NVIDIA GeForce RTX 5070 Ti 16 GB (Blackwell, 32-lane waves only, mesh shaders), driver 616.64, Ryzen 7 9800X3D, Windows 11 Home 26300, Rust 1.100.0 MSVC, debug, D3D12 debug layer installed.
  • cargo build --workspace, then XCL_REQUIRE_GPU=mesh cargo test --workspace -- --test-threads=4: 771 passed, 0 failed, 41 ignored. SKIPPED (no wave64): gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware.
  • The new tests ran and passed: console_madak_f32_disassembles.
  • Same head on the AMD Radeon iGPU of the 9800X3D (RDNA2, XCL_ADAPTER=radeon), cargo test --workspace -- --test-threads=4: 771 passed, 0 failed, 41 ignored, no skips.

Not tested

  • a release build, a game (test run only).

AI use

  • Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
<!-- greyfinch-sync:ivall/xcl:comment:7138464079 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1467#issuecomment-7138464079). Originally posted by [futurepro62](https://github.com/futurepro62) on 2026-11-24T16:57:19Z. --- Full-suite run, since this PR has no test report yet. Tested exact head `0293e77` (on its base `b7aa9f3`). **Tested** - NVIDIA GeForce RTX 5070 Ti 16 GB (Blackwell, 32-lane waves only, mesh shaders), driver 616.64, Ryzen 7 9800X3D, Windows 11 Home 26300, Rust 1.100.0 MSVC, debug, D3D12 debug layer installed. - `cargo build --workspace`, then `XCL_REQUIRE_GPU=mesh cargo test --workspace -- --test-threads=4`: **771 passed, 0 failed, 41 ignored**. SKIPPED (no wave64): `gpu_geometry_wave32_prefix_count_over_a_mask`, `gpu_wave32_program_in_wave64_hardware`. - The new tests ran and passed: `console_madak_f32_disassembles`. - Same head on the AMD Radeon iGPU of the 9800X3D (RDNA2, `XCL_ADAPTER=radeon`), `cargo test --workspace -- --test-threads=4`: **771 passed, 0 failed, 41 ignored**, no skips. **Not tested** - a release build, a game (test run only). **AI use** - Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
DavidM1911 commented 2026-11-24 19:07:44 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-24T18:53:04Z.


Verification on RTX 3060 Ti (Windows 11), branch merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, ~21 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling; clean on single-threaded rerun — same flake seen on unmodified main.)

Thanks!

<!-- greyfinch-sync:ivall/xcl:comment:7141286910 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1467#issuecomment-7141286910). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-24T18:53:04Z. --- Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~21 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling; clean on single-threaded rerun — same flake seen on unmodified `main`.) Thanks!
Toons29 commented 2026-11-25 04:10:32 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Toons29 on 2026-11-25T03:31:56Z.


Regression run of 0293e77b on the retail title, for this PR's Regression run section. Both blocks are from scripts/smoke.ps1 as printed, not edited: main on 4178e888, this PR on its head commit with no uncommitted changes, same title and time.

xcl-smoke v1
commit: 4178e888c0b5be50a2887eda45cdb832763b68a4
gpu: AMD Radeon RX 9070
title: game.exe
seconds: 60
exit: 0x0
frames shown: 1618 (PresentX 1618)
presents per 2 s (last 3): 61 60 60
device removals: 0
crashes: 0
peak commit: 14831 MB
xcl-smoke v1
commit: 0293e77b66e196697dcd829fa61cb5a16ba64fdb
gpu: AMD Radeon RX 9070
title: game.exe
seconds: 60
exit: 0x0
frames shown: 1631 (PresentX 1631)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14815 MB

Against the limits in CONTRIBUTING.md: 101 % of main's frames, 100 % of its peak commit, no crash, no device removal.

AMD Radeon RX 9070 (RDNA4, driver 32.0.32029.2010), Ryzen 7 7800X3D, 32 GB, Windows 11 build 26300, Rust 1.100.0, cargo build --release -p xcl, 60 s, XCL_NETWORK=0. This is a regression check only: it does not show whether the run reaches the code this PR changes.

AI use: Claude Code (Claude Opus 5.5) built both trees and ran scripts/smoke.ps1; I checked the blocks before posting.

<!-- greyfinch-sync:ivall/xcl:comment:7152001896 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1467#issuecomment-7152001896). Originally posted by [Toons29](https://github.com/Toons29) on 2026-11-25T03:31:56Z. --- Regression run of `0293e77b` on the retail title, for this PR's **Regression run** section. Both blocks are from `scripts/smoke.ps1` as printed, not edited: `main` on `4178e888`, this PR on its head commit with no uncommitted changes, same title and time. ``` xcl-smoke v1 commit: 4178e888c0b5be50a2887eda45cdb832763b68a4 gpu: AMD Radeon RX 9070 title: game.exe seconds: 60 exit: 0x0 frames shown: 1618 (PresentX 1618) presents per 2 s (last 3): 61 60 60 device removals: 0 crashes: 0 peak commit: 14831 MB ``` ``` xcl-smoke v1 commit: 0293e77b66e196697dcd829fa61cb5a16ba64fdb gpu: AMD Radeon RX 9070 title: game.exe seconds: 60 exit: 0x0 frames shown: 1631 (PresentX 1631) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 14815 MB ``` Against the limits in CONTRIBUTING.md: 101 % of `main`'s frames, 100 % of its peak commit, no crash, no device removal. AMD Radeon RX 9070 (RDNA4, driver 32.0.32029.2010), Ryzen 7 7800X3D, 32 GB, Windows 11 build 26300, Rust 1.100.0, `cargo build --release -p xcl`, 60 s, `XCL_NETWORK=0`. This is a regression check only: it does not show whether the run reaches the code this PR changes. AI use: Claude Code (Claude Opus 5.5) built both trees and ran `scripts/smoke.ps1`; I checked the blocks before posting.
github-actions[bot] commented 2026-11-29 07:40:56 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by github-actions[bot] on 2026-11-29T07:40:56Z.


Nothing has happened on this PR for 3 days, so it is marked stale and will be closed in 4 days. A push or a comment takes the mark off: rebase it onto main if it conflicts, and say in one line what it still fixes. If it only waits for a maintainer, a comment saying so is enough.

<!-- greyfinch-sync:ivall/xcl:comment:7252624197 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1467#issuecomment-7252624197). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-29T07:40:56Z. --- Nothing has happened on this PR for 3 days, so it is marked `stale` and will be closed in 4 days. A push or a comment takes the mark off: rebase it onto `main` if it conflicts, and say in one line what it still fixes. If it only waits for a maintainer, a comment saying so is enough.
Foniass commented 2026-12-01 05:51:58 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T05:51:58Z.


Triage (#1607) – head 0293e77

No open or merged PR makes the same change. The test encodes v_madak_f32 v1, v2, v3, 0x3f800000 (VOP2 opcode 0x21, literal last) and matches the MADAK operand order in gpu/rdna2_xbox.rs; it complements the existing v_madmk_f32 case in console_legacy_mad_mac. No problems found in the diff.

Recommendation: keep open.

AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

<!-- greyfinch-sync:ivall/xcl:comment:7302221233 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1467#issuecomment-7302221233). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T05:51:58Z. --- **Triage (#1607)** – head 0293e77 No open or merged PR makes the same change. The test encodes `v_madak_f32 v1, v2, v3, 0x3f800000` (VOP2 opcode 0x21, literal last) and matches the MADAK operand order in `gpu/rdna2_xbox.rs`; it complements the existing `v_madmk_f32` case in `console_legacy_mad_mac`. No problems found in the diff. Recommendation: keep open. AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/1467:upstream-pr/1467'
git switch 'upstream-pr/1467'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/1467'
git switch 'upstream-pr/1467'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/1467'
git switch 'upstream-pr/1467'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/1467'
git switch 'main'
git merge --squash 'upstream-pr/1467'
git switch 'main'
git merge --ff-only 'upstream-pr/1467'
git switch 'main'
git merge 'upstream-pr/1467'
git push origin 'main'
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
xcl-dev/xcl!1457
No description provided.