gpu: exercise per-case pixel batch errors and device removal #2227

Merged
RavenCurseBurg merged 1 commit from upstream-pr/2235 into main 2026-11-25 07:09:46 +00:00
RavenCurseBurg commented 2026-11-25 06:47:21 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by RavenCurseBurg on 2026-11-25T06:47:21Z.


Refs #448. The temporary control build reported in #508 exercised two failure paths in the shared-device pixel batch. This patch makes both checks reproducible in CTest.

Each control starts with three successful, distinct color readbacks through the ordinary batch command. A separate test command then runs the same draw loop and injects one event after the second readback.

Event Required case results Required evidence
Add an application error to the D3D12 info queue pass, error, pass Counts 0/1/0, the diagnostic belongs to the second case, process exit 1
Remove the logical D3D12 device pass, error, error The final case reports DXGI_ERROR_DEVICE_REMOVED at the pre-draw check, process exit 1

Run ctest --preset dev --no-tests=error -R '^pixel_batch_(debug|removal)_(warp|hardware)$' -V. Missing debug-layer and device-interface capabilities have independent skip results.

At bbae5b80, the Windows 2025 build and WARP mutation run passed both controls with the debug layer enabled. Retaining the previous case's messages turned the third status into an error and failed the debug test. Removing the pre-draw device check failed the removal test even though both remaining cases still reported errors.

The packaged binary from that same revision also passed the device-removal test on local WARP and a physical D3D12 adapter. Both local debug-message tests returned capability skip 77 because the layer was unavailable. The documentation checker passed 417 links and the bidi check passed 1,519 tracked files.

AI-assisted with Codex (GPT-6.2 Astra xhigh).

<!-- greyfinch-sync:R0Y00/Xbox2Windows:issue:6598912953 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2235). Originally posted by [RavenCurseBurg](https://github.com/RavenCurseBurg) on 2026-11-25T06:47:21Z. --- Refs #448. The temporary control build reported in #508 exercised two failure paths in the shared-device pixel batch. This patch makes both checks reproducible in CTest. Each control starts with three successful, distinct color readbacks through the ordinary batch command. A separate test command then runs the same draw loop and injects one event after the second readback. | Event | Required case results | Required evidence | | --- | --- | --- | | Add an application error to the D3D12 info queue | pass, error, pass | Counts 0/1/0, the diagnostic belongs to the second case, process exit 1 | | Remove the logical D3D12 device | pass, error, error | The final case reports DXGI_ERROR_DEVICE_REMOVED at the pre-draw check, process exit 1 | Run `ctest --preset dev --no-tests=error -R '^pixel_batch_(debug|removal)_(warp|hardware)$' -V`. Missing debug-layer and device-interface capabilities have independent skip results. At `bbae5b80`, the [Windows 2025 build and WARP mutation run](https://github.com/RavenCurseBurg/Xbox2Windows/actions/runs/45562682911) passed both controls with the debug layer enabled. Retaining the previous case's messages turned the third status into an error and failed the debug test. Removing the pre-draw device check failed the removal test even though both remaining cases still reported errors. The packaged binary from that same revision also passed the device-removal test on local WARP and a physical D3D12 adapter. Both local debug-message tests returned capability skip 77 because the layer was unavailable. The documentation checker passed 417 links and the bidi check passed 1,519 tracked files. AI-assisted with Codex (GPT-6.2 Astra xhigh).
tedin7 commented 2026-11-25 07:01:10 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T07:00:05Z.

Review: COMMENTED


Review of head bbae5b80c8.

Logic: the new batch controls look correct. The run_pixel_batch template keeps the old per-case error handling. The debug control adds one application message after case 1. The removal control calls RemoveDevice after case 1 and skips on E_NOINTERFACE. The expected statuses (pass/error/pass and pass/error/error) and exit code 1 match that behavior. No P1 or P2 found. No other open PR touches the same batch controls.

Commands executed locally:

  • python3 tests/docs_links_check.py -> pass (18 Markdown files, 417 links)
  • python3 tests/bidi_controls_check.py -> pass (no bidirectional controls)
  • git diff --check origin/main...HEAD -> clean
  • Win2025 dev and release, -R '^pixel_batch_(debug|removal)_(warp|hardware)$|^pixel_cb_read_warp$': 100% passed in both. pixel_batch_removal_warp and pixel_cb_read_warp ran and passed. pixel_batch_debug_warp and pixel_batch_debug_hardware reported capability SKIP, because the debug layer is not available on that VM.
  • CI Build and test on Windows: SUCCESS.

Gaps (no approval from this review):

  • The debug-layer half (error counts 0/1/0) was not exercised on Win2025, only skipped.
  • No mutation of the C++ control logic was run, because it cannot be built on Linux. So there is no proof yet that the new tests fail when the controls are broken.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6053174663 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2235#pullrequestreview-6053174663). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T07:00:05Z. **Review:** COMMENTED --- Review of head bbae5b80c8346c52653024c362f8a0f8675e9802. Logic: the new batch controls look correct. The `run_pixel_batch` template keeps the old per-case error handling. The debug control adds one application message after case 1. The removal control calls `RemoveDevice` after case 1 and skips on `E_NOINTERFACE`. The expected statuses (pass/error/pass and pass/error/error) and exit code 1 match that behavior. No P1 or P2 found. No other open PR touches the same batch controls. Commands executed locally: - `python3 tests/docs_links_check.py` -> pass (18 Markdown files, 417 links) - `python3 tests/bidi_controls_check.py` -> pass (no bidirectional controls) - `git diff --check origin/main...HEAD` -> clean - Win2025 dev and release, `-R '^pixel_batch_(debug|removal)_(warp|hardware)$|^pixel_cb_read_warp$'`: 100% passed in both. `pixel_batch_removal_warp` and `pixel_cb_read_warp` ran and passed. `pixel_batch_debug_warp` and `pixel_batch_debug_hardware` reported capability SKIP, because the debug layer is not available on that VM. - CI `Build and test on Windows`: SUCCESS. Gaps (no approval from this review): - The debug-layer half (error counts 0/1/0) was not exercised on Win2025, only skipped. - No mutation of the C++ control logic was run, because it cannot be built on Linux. So there is no proof yet that the new tests fail when the controls are broken. AI-assisted; commands listed were executed locally.
upstream-sync closed this pull request 2026-11-25 08:04:53 +00:00
RavenCurseBurg commented 2026-11-25 08:05:04 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by RavenCurseBurg on 2026-11-25T07:07:43Z.


The two checks you could not run on your VM were exercised on a separate Windows 2025 runner at the reviewed head, bbae5b80.

  • WARP with the debug layer enabled, step 5 ran both tests. The debug case recorded 0/1/0 errors, the middle diagnostic was D3D12 1: pixel batch control error, and the statuses were pass/error/pass. The removal case recorded pass/error/error and 0x887a0005 before the third draw.
  • Two C++ mutations rebuilt and run with MSVC, step 6 shows each broken binary failing its own CTest. Keeping the previous case's info-queue messages made case 2 report error. Removing the pre-draw device check still produced pass/error/error, but the removal test rejected the different diagnostic.

The workflow checks out the exact PR SHA for the initial build and applies each mutation separately. Both logs are public.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7155518116 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2235#issuecomment-7155518116). Originally posted by [RavenCurseBurg](https://github.com/RavenCurseBurg) on 2026-11-25T07:07:43Z. --- The two checks you could not run on your VM were exercised on a separate Windows 2025 runner at the reviewed head, `bbae5b80`. - [WARP with the debug layer enabled, step 5](https://github.com/RavenCurseBurg/Xbox2Windows/actions/runs/45562682911/job/139029921669#step:5:1) ran both tests. The debug case recorded 0/1/0 errors, the middle diagnostic was `D3D12 1: pixel batch control error`, and the statuses were pass/error/pass. The removal case recorded pass/error/error and 0x887a0005 before the third draw. - [Two C++ mutations rebuilt and run with MSVC, step 6](https://github.com/RavenCurseBurg/Xbox2Windows/actions/runs/45562682911/job/139029921669#step:6:1) shows each broken binary failing its own CTest. Keeping the previous case's info-queue messages made case 2 report error. Removing the pre-draw device check still produced pass/error/error, but the removal test rejected the different diagnostic. The workflow checks out the exact PR SHA for the initial build and applies each mutation separately. Both logs are public.
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
R0Y00/Xbox2Windows!2227
No description provided.