GPU: treat VICTORY_D3D12_WARP=0 as unset #639

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

@⁠Quat3rnion on GitHub · 2026-11-24 06:04 UTC · original
Quat3rnion:victory-warp-zero → main · +33 −1 · 3 files · 1 commits · closed without merging

What

The diagnostics switch used var_os(...).is_some(), so an explicit
VICTORY_D3D12_WARP=0 still selected the software adapter; the workaround
was to delete the variable. The value is now parsed in a host-independent
helper where 0 means unset, while 1, empty and other values keep their
existing meaning. Fixes issue #610.

An AI tool wrote part of this change.

Tested

  • Linux: cargo test --workspace: 165 passed, 0 failed, 3 ignored. A new unit test checks unset, 0, 1, empty and an arbitrary value.
  • Windows cross-build: cargo check --target x86_64-pc-windows-gnu --workspace --tests passes. No Windows host here, so adapter selection itself was not exercised.
  • cargo xtask policy passes (151 files ok). No game files or data from them were added.

Checklist

  • Workspace tests and Windows cross-check pass.
  • cargo xtask policy passes. No game files or data from them were added.
  • AI authorship is disclosed above.
**@⁠Quat3rnion** on GitHub · 2026-11-24 06:04 UTC · [original](https://github.com/Marvisak/VIctory/pull/639) `Quat3rnion:victory-warp-zero` → `main` · +33 −1 · 3 files · 1 commits · closed without merging ## What The diagnostics switch used `var_os(...).is_some()`, so an explicit `VICTORY_D3D12_WARP=0` still selected the software adapter; the workaround was to delete the variable. The value is now parsed in a host-independent helper where `0` means unset, while `1`, empty and other values keep their existing meaning. Fixes issue #610. An AI tool wrote part of this change. ## Tested - Linux: `cargo test --workspace`: 165 passed, 0 failed, 3 ignored. A new unit test checks unset, `0`, `1`, empty and an arbitrary value. - Windows cross-build: `cargo check --target x86_64-pc-windows-gnu --workspace --tests` passes. No Windows host here, so adapter selection itself was not exercised. - `cargo xtask policy` passes (151 files ok). No game files or data from them were added. ## Checklist - [x] Workspace tests and Windows cross-check pass. - [x] `cargo xtask policy` passes. No game files or data from them were added. - [x] AI authorship is disclosed above.
The diagnostics switch used var_os().is_some(), so an explicit 0 still selected the software adapter and a launcher had to delete the variable to use hardware. Parse the value in a host-independent helper where 0 means unset, and test unset, 0, 1, empty and other values on Linux. Addresses issue #610.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:11:06 +00:00
github-bot closed this pull request 2026-11-26 04:11:06 +00:00
Author
Owner

@⁠Quat3rnion on GitHub · 2026-11-24 06:15 UTC · original

Duplicate of #615, which covers all six VICTORY_* switches rather than WARP alone. Closing in favour of that PR.

**@⁠Quat3rnion** on GitHub · 2026-11-24 06:15 UTC · [original](https://github.com/Marvisak/VIctory/pull/639#issuecomment-7123754587) Duplicate of #615, which covers all six VICTORY_* switches rather than WARP alone. Closing in favour of that PR.

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!639
No description provided.