GPU: implement IDXGIAdapter2::GetDesc2 #1893

Closed
github-bot wants to merge 1 commit from gh-pr/1893/head into gh-pr/1893/base
Owner

@⁠DoubleD17 on GitHub · 2026-11-25 00:16 UTC · original
DoubleD17:port/fxceless-345 → main · +100 −7 · 1 files · 1 commits · closed without merging

The DXGI shim advertises IDXGIAdapter2 through QueryInterface, but its GetDesc2 entry is still unimplemented. Wire the descriptor method and reuse the logical adapter identity and memory information returned by GetDesc. Check the vtable slot and descriptor layout against the Windows bindings, and return E_INVALIDARG for a null output.

On Windows x64 with Rust 1.98.1 and MSVC, the new synthetic test detected the unwired method on base e82a6ad. The two DXGI unit tests passed on 211364a with cargo test --offline --locked --jobs 2 -p victory-gpu --features diagnostics --lib dxgi::tests::. This verifies the adapter API on the CPU.

Adapted from fxceless/victory-fork #345.

AI-assisted.

**@⁠DoubleD17** on GitHub · 2026-11-25 00:16 UTC · [original](https://github.com/Marvisak/VIctory/pull/1893) `DoubleD17:port/fxceless-345` → `main` · +100 −7 · 1 files · 1 commits · closed without merging The DXGI shim advertises IDXGIAdapter2 through QueryInterface, but its GetDesc2 entry is still unimplemented. Wire the descriptor method and reuse the logical adapter identity and memory information returned by GetDesc. Check the vtable slot and descriptor layout against the Windows bindings, and return E_INVALIDARG for a null output. On Windows x64 with Rust 1.98.1 and MSVC, the new synthetic test detected the unwired method on base e82a6ad. The two DXGI unit tests passed on 211364a with `cargo test --offline --locked --jobs 2 -p victory-gpu --features diagnostics --lib dxgi::tests::`. This verifies the adapter API on the CPU. Adapted from [fxceless/victory-fork #345](https://github.com/fxceless/victory-fork/pull/345). AI-assisted.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:47:50 +00:00
github-bot closed this pull request 2026-11-26 04:47:50 +00:00
Author
Owner

@⁠Marvisak on GitHub · 2026-11-25 02:17 UTC · original · edited 2026-11-25 06:27 UTC

Automated triage for the maintainers.

Needs work: evidence for the new return values. The rebase fixed the conflict, and the head merges cleanly. In crates/victory-gpu/src/dxgi.rs, the PR wires slot 11 (0x58) of ADAPTER_FUNCTIONS to a new adapter_description2. That matches the "adapter 3 + 1 + 1" layout already noted there. It reuses GetDesc's values through describe_adapter and checks the layout against the Windows bindings at compile time. The mechanics look right. However, this is a new runtime return value with no evidence behind it:

  • nothing shows that a title calls this slot (for example, a log of the missing 0x58 stub being hit);
  • flags = 0 and DMA-buffer preemption granularity are chosen, not taken from the console's behaviour or public documentation.

Please add the evidence for both. Also note that slot 10 (GetDesc1) is still unwired; if a title reaches GetDesc2, it likely reaches that one too.

CI: passing (check).


Generated by Claude Code

**@⁠Marvisak** on GitHub · 2026-11-25 02:17 UTC · [original](https://github.com/Marvisak/VIctory/pull/1893#issuecomment-7150541751) · edited 2026-11-25 06:27 UTC <!-- victory-triage v1 head=15a1e539851b82461d2f9edccc312bc6a3b56012 verdict=needs-work at=2026-11-25T06:27:19Z --> Automated triage for the maintainers. **Needs work: evidence for the new return values.** The rebase fixed the conflict, and the head merges cleanly. In `crates/victory-gpu/src/dxgi.rs`, the PR wires slot 11 (0x58) of `ADAPTER_FUNCTIONS` to a new `adapter_description2`. That matches the "adapter 3 + 1 + 1" layout already noted there. It reuses `GetDesc`'s values through `describe_adapter` and checks the layout against the Windows bindings at compile time. The mechanics look right. However, this is a new runtime return value with no evidence behind it: - nothing shows that a title calls this slot (for example, a log of the missing 0x58 stub being hit); - `flags = 0` and DMA-buffer preemption granularity are chosen, not taken from the console's behaviour or public documentation. Please add the evidence for both. Also note that slot 10 (`GetDesc1`) is still unwired; if a title reaches `GetDesc2`, it likely reaches that one too. CI: passing (`check`). --- _Generated by [Claude Code](https://claude.ai/code)_

Pull request closed

This discussion has been locked. Commenting is limited to contributors.
No reviewers
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.

Dependencies

No dependencies set

Reference
github/Marvisak--VIctory!1893
No description provided.