docs: an inventory of the switches read by non-test code but documented nowhere (59, or 53 after #486) #582

Open
opened 2026-11-28 10:06:07 +00:00 by AnastasisKon · 6 comments
AnastasisKon commented 2026-11-28 10:06:07 +00:00 (Migrated from github.com)
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by AnastasisKon on 2026-11-28T10:06:07Z.


Measured by scanning the tree, not by memory: VICTORY_* names read by non-test code (excluding *_tests.rs/tests.rs) that appear in none of docs/, README.md, victory.example.toml or tools/**/*.sh. 165 names are read in non-test code; 59 are undocumented. Six of those are already covered by the open #486, which leaves 53.

I am not claiming this list is all user-facing — the buckets below are my reading of the code at each site, and the maintainer should delete or relabel whatever does not belong. Per AGENTS.md, "new diagnostics are off by default, behind a VICTORY_* environment variable, and documented"; this is the backlog of that rule, so it can be split into per-area issues or picked off one by one.

Looks user-facing, and a tester would benefit (the valuable half)

Name Read at What it appears to do
VICTORY_AUDIO_CAPTURE / _OF apps/victory/src/main.rs:204, hle/src/modules/audio/capture.rs:49 record what the title plays to a WAV through process loopback (#17 evidence)
VICTORY_CAPTURE, _FRAMES, _WORLD gpu/src/capture.rs:2,19,20 frame capture, and the world-frame marker the other dumps count from
VICTORY_CRASH_BREAKPOINTS, VICTORY_CRASH_SAVE, VICTORY_SKIP_TITLE_INT3 loader/src/crash.rs:12,56, apps/victory/src/run.rs:271 crash triage: save state at a fault, skip a title int3
VICTORY_D3D12_DEBUG, _DRED, _GBV, _WARP gpu/src/host.rs:85,876,190,223 the device layer's own debugging, and device-removed reports
VICTORY_LOG core/src/logging.rs:3 log level — the first thing anyone sets
VICTORY_WATCH, VICTORY_POKE, VICTORY_TRAP_LOG apps/victory/src/run.rs:290,318, loader/src/thunks.rs:125 traps, page watches, single-call probes
VICTORY_SKIP_CPU_CHECK, VICTORY_SKIP_PIPELINES apps/victory/src/run.rs:8, gpu/src/pipeline.rs:537 bisection switches
VICTORY_NARROW_WAVES, VICTORY_WARP, VICTORY_PC_DXC, VICTORY_DEBUG_ELSEWHERE gpu/src/shader_cache.rs:244, shader/src/emit/{host.rs:126,mod.rs:882,862} translation switches, part of the cache key
VICTORY_XMA_STREAMS, VICTORY_XMA_REFERENCE formats/src/xma.rs:1772,1818 the XMA decoder work
VICTORY_COPIES_IN_VIDEO_MEMORY, VICTORY_COPY_MODE gpu/src/host.rs:3529, gpu/src/copystat.rs:3 copy accounting
VICTORY_WINDOW_MAX hle/src/modules/lifecycle.rs:198 window behaviour
VICTORY_PREBUILD_KEYS apps/victory/src/prebuild.rs:175 the pre-build's key list
VICTORY_EMIT_DUMP apps/victory/src/translate.rs:163 emitted-code dumps

Already covered by #486 (listed for completeness)

VICTORY_DSTORAGE_LOG, VICTORY_FRAME_DUMP, VICTORY_DUMP_WRITERS, VICTORY_PIPELINE_LOG, VICTORY_TRACE_SHADERS, VICTORY_GPU_TIMING.

Internal plumbing between our own processes — arguably should stay undocumented, but named

VICTORY_AUDIO_CAPTURE_OF, VICTORY_EXIT_CHILD, VICTORY_HOST_LOCK_CHILD, VICTORY_RELAUNCHED_FROM, VICTORY_SAVE_CHILD, VICTORY_SAVE_OP, VICTORY_SAVE_STOP, VICTORY_SHADER_SOURCE_HASH, VICTORY_TEST_ENV_5E2B, VICTORY_TEST_CLOCK_RATE, VICTORY_TEST_CRASH_LOG.

Test and example harness — probably fine undocumented

VICTORY_BCPACK_CASES, VICTORY_BCPACK_TABLES, VICTORY_CASE_TEST, VICTORY_CONTAINER, VICTORY_DXIL, VICTORY_PAIRS, VICTORY_PS, VICTORY_VS, VICTORY_RECT, VICTORY_WAVE32, VICTORY_REF_PS, VICTORY_REF_VS, VICTORY_UCRT_MISSING, VICTORY_UCRT_T, VICTORY_WRITE_DXIL.

Also found while measuring, and a different problem

docs/native-host.md names two switches nothing reads any more: VICTORY_DEBUG_PS_INPUTS (line 826, where the docs already say "not wired after the merge") and VICTORY_TRACE_DISPATCH_INPUTS (line 1735, "a local diagnostic"). Worth deciding whether they are history to keep or stale text to drop.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:issue:6663125770 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/582). Originally posted by [AnastasisKon](https://github.com/AnastasisKon) on 2026-11-28T10:06:07Z. --- Measured by scanning the tree, not by memory: `VICTORY_*` names read by non-test code (excluding `*_tests.rs`/`tests.rs`) that appear in none of `docs/`, `README.md`, `victory.example.toml` or `tools/**/*.sh`. **165** names are read in non-test code; **59** are undocumented. Six of those are already covered by the open #486, which leaves 53. I am not claiming this list is all user-facing — the buckets below are my reading of the code at each site, and the maintainer should delete or relabel whatever does not belong. Per `AGENTS.md`, "new diagnostics are off by default, behind a `VICTORY_*` environment variable, and documented"; this is the backlog of that rule, so it can be split into per-area issues or picked off one by one. ### Looks user-facing, and a tester would benefit (the valuable half) | Name | Read at | What it appears to do | |---|---|---| | `VICTORY_AUDIO_CAPTURE` / `_OF` | `apps/victory/src/main.rs:204`, `hle/src/modules/audio/capture.rs:49` | record what the title plays to a WAV through process loopback (#17 evidence) | | `VICTORY_CAPTURE`, `_FRAMES`, `_WORLD` | `gpu/src/capture.rs:2,19,20` | frame capture, and the world-frame marker the other dumps count from | | `VICTORY_CRASH_BREAKPOINTS`, `VICTORY_CRASH_SAVE`, `VICTORY_SKIP_TITLE_INT3` | `loader/src/crash.rs:12,56`, `apps/victory/src/run.rs:271` | crash triage: save state at a fault, skip a title `int3` | | `VICTORY_D3D12_DEBUG`, `_DRED`, `_GBV`, `_WARP` | `gpu/src/host.rs:85,876,190,223` | the device layer's own debugging, and device-removed reports | | `VICTORY_LOG` | `core/src/logging.rs:3` | log level — the first thing anyone sets | | `VICTORY_WATCH`, `VICTORY_POKE`, `VICTORY_TRAP_LOG` | `apps/victory/src/run.rs:290,318`, `loader/src/thunks.rs:125` | traps, page watches, single-call probes | | `VICTORY_SKIP_CPU_CHECK`, `VICTORY_SKIP_PIPELINES` | `apps/victory/src/run.rs:8`, `gpu/src/pipeline.rs:537` | bisection switches | | `VICTORY_NARROW_WAVES`, `VICTORY_WARP`, `VICTORY_PC_DXC`, `VICTORY_DEBUG_ELSEWHERE` | `gpu/src/shader_cache.rs:244`, `shader/src/emit/{host.rs:126,mod.rs:882,862}` | translation switches, part of the cache key | | `VICTORY_XMA_STREAMS`, `VICTORY_XMA_REFERENCE` | `formats/src/xma.rs:1772,1818` | the XMA decoder work | | `VICTORY_COPIES_IN_VIDEO_MEMORY`, `VICTORY_COPY_MODE` | `gpu/src/host.rs:3529`, `gpu/src/copystat.rs:3` | copy accounting | | `VICTORY_WINDOW_MAX` | `hle/src/modules/lifecycle.rs:198` | window behaviour | | `VICTORY_PREBUILD_KEYS` | `apps/victory/src/prebuild.rs:175` | the pre-build's key list | | `VICTORY_EMIT_DUMP` | `apps/victory/src/translate.rs:163` | emitted-code dumps | ### Already covered by #486 (listed for completeness) `VICTORY_DSTORAGE_LOG`, `VICTORY_FRAME_DUMP`, `VICTORY_DUMP_WRITERS`, `VICTORY_PIPELINE_LOG`, `VICTORY_TRACE_SHADERS`, `VICTORY_GPU_TIMING`. ### Internal plumbing between our own processes — arguably should stay undocumented, but named `VICTORY_AUDIO_CAPTURE_OF`, `VICTORY_EXIT_CHILD`, `VICTORY_HOST_LOCK_CHILD`, `VICTORY_RELAUNCHED_FROM`, `VICTORY_SAVE_CHILD`, `VICTORY_SAVE_OP`, `VICTORY_SAVE_STOP`, `VICTORY_SHADER_SOURCE_HASH`, `VICTORY_TEST_ENV_5E2B`, `VICTORY_TEST_CLOCK_RATE`, `VICTORY_TEST_CRASH_LOG`. ### Test and example harness — probably fine undocumented `VICTORY_BCPACK_CASES`, `VICTORY_BCPACK_TABLES`, `VICTORY_CASE_TEST`, `VICTORY_CONTAINER`, `VICTORY_DXIL`, `VICTORY_PAIRS`, `VICTORY_PS`, `VICTORY_VS`, `VICTORY_RECT`, `VICTORY_WAVE32`, `VICTORY_REF_PS`, `VICTORY_REF_VS`, `VICTORY_UCRT_MISSING`, `VICTORY_UCRT_T`, `VICTORY_WRITE_DXIL`. ### Also found while measuring, and a different problem `docs/native-host.md` names two switches nothing reads any more: `VICTORY_DEBUG_PS_INPUTS` (line 826, where the docs already say "not wired after the merge") and `VICTORY_TRACE_DISPATCH_INPUTS` (line 1735, "a local diagnostic"). Worth deciding whether they are history to keep or stale text to drop.
AnastasisKon commented 2026-11-28 10:07:06 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by AnastasisKon on 2026-11-28T10:07:06Z.


/claim

Picking off the user-facing piece: I'll recompute the undocumented VICTORY_* set on current main, then document the clearly user-facing ones (log level, audio capture, frame capture) in docs/native-host.md, verifying each at its read site. One PR.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7237682570 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/582#issuecomment-7237682570). Originally posted by [AnastasisKon](https://github.com/AnastasisKon) on 2026-11-28T10:07:06Z. --- /claim Picking off the user-facing piece: I'll recompute the undocumented VICTORY_* set on current main, then document the clearly user-facing ones (log level, audio capture, frame capture) in docs/native-host.md, verifying each at its read site. One PR.
github-actions[bot] commented 2026-11-28 10:07:15 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by github-actions[bot] on 2026-11-28T10:07:15Z.


Claimed by @AnastasisKon. Open a draft pull request with Refs #582 in its description within 24 hours, or the claim expires.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7237684341 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/582#issuecomment-7237684341). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-28T10:07:15Z. --- Claimed by @AnastasisKon. Open a draft pull request with `Refs #582` in its description within 24 hours, or the claim expires.
AnastasisKon commented 2026-11-28 10:32:11 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by AnastasisKon on 2026-11-28T10:32:11Z.


Recounted, and my original figure was wrong in two ways; both are corrected here.

The count. It said 59, or 53 after #486. Measured again against docs/*.md, README.md and victory.example.toml (which I had left out, and which documents VICTORY_CONFIG, VICTORY_GAME_DIR, VICTORY_CACHE_DIR, VICTORY_DATA_DIR, VICTORY_FIDELITYFX_DIR and VICTORY_TEST_TITLES), and counting only names in non-test, non-example Rust: 43 undocumented before this week's work, 34 now.

What landed, each as its own change:

  • #486: six native-host diagnostics.
  • the crash-triage bullet: VICTORY_SKIP_TITLE_INT3, VICTORY_CRASH_BREAKPOINTS, VICTORY_CRASH_SAVE (which I have since extended to the native host).
  • the diagnostics-build note: a switch marked "Diagnostics build only" is compiled out of a plain release build, which is why one can look broken.
  • VICTORY_LOG, plus a new subsection, "The D3D12 path's own switches", for VICTORY_CAPTURE, VICTORY_CAPTURE_FRAMES, VICTORY_CAPTURE_WORLD, VICTORY_WINDOW_MAX, VICTORY_COPIES_IN_VIDEO_MEMORY, VICTORY_COPY_MODE and VICTORY_AUDIO_CAPTURE (with VICTORY_AUDIO_CAPTURE_OF, which the recorder sets in its own child, not the user) — each naming the native host's equivalent, so a switch that does nothing on macOS says so.

What is left (34) falls into three groups, and only the first is worth a page of its own:

  • the shader tools: VICTORY_DXIL, VICTORY_PC_DXC, VICTORY_WARP, VICTORY_REF_VS, VICTORY_REF_PS, VICTORY_DEBUG_ELSEWHERE, VICTORY_EMIT_DUMP, VICTORY_PAIRS, VICTORY_PREBUILD_KEYS, VICTORY_SHADER_SOURCE_HASH;
  • the D3D12 debug layer and its bits: VICTORY_D3D12_DEBUG, VICTORY_D3D12_DRED, VICTORY_D3D12_GBV, VICTORY_D3D12_WARP;
  • test and child-process plumbing, which arguably should not be documented as switches at all: VICTORY_TEST_*, VICTORY_CASE_TEST, VICTORY_EXIT_CHILD, VICTORY_HOST_LOCK_CHILD, VICTORY_SAVE_*, VICTORY_UCRT_*, VICTORY_RELAUNCHED_FROM, VICTORY_BCPACK_*, VICTORY_XMA_*, VICTORY_TRAP_LOG, VICTORY_NARROW_WAVES, VICTORY_POKE, VICTORY_SKIP_CPU_CHECK, VICTORY_WRITE_DXIL.

Two stale names remain in docs/native-host.md as reported: VICTORY_DEBUG_PS_INPUTS and VICTORY_TRACE_DISPATCH_INPUTS are read nowhere in the tree.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7237959448 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/582#issuecomment-7237959448). Originally posted by [AnastasisKon](https://github.com/AnastasisKon) on 2026-11-28T10:32:11Z. --- Recounted, and my original figure was wrong in two ways; both are corrected here. **The count.** It said 59, or 53 after #486. Measured again against `docs/*.md`, `README.md` **and `victory.example.toml`** (which I had left out, and which documents `VICTORY_CONFIG`, `VICTORY_GAME_DIR`, `VICTORY_CACHE_DIR`, `VICTORY_DATA_DIR`, `VICTORY_FIDELITYFX_DIR` and `VICTORY_TEST_TITLES`), and counting only names in non-test, non-example Rust: **43** undocumented before this week's work, **34** now. **What landed**, each as its own change: - #486: six native-host diagnostics. - the crash-triage bullet: `VICTORY_SKIP_TITLE_INT3`, `VICTORY_CRASH_BREAKPOINTS`, `VICTORY_CRASH_SAVE` (which I have since extended to the native host). - the diagnostics-build note: a switch marked "Diagnostics build only" is compiled out of a plain release build, which is why one can look broken. - `VICTORY_LOG`, plus a new subsection, "The D3D12 path's own switches", for `VICTORY_CAPTURE`, `VICTORY_CAPTURE_FRAMES`, `VICTORY_CAPTURE_WORLD`, `VICTORY_WINDOW_MAX`, `VICTORY_COPIES_IN_VIDEO_MEMORY`, `VICTORY_COPY_MODE` and `VICTORY_AUDIO_CAPTURE` (with `VICTORY_AUDIO_CAPTURE_OF`, which the recorder sets in its own child, not the user) — each naming the native host's equivalent, so a switch that does nothing on macOS says so. **What is left (34)** falls into three groups, and only the first is worth a page of its own: - the shader tools: `VICTORY_DXIL`, `VICTORY_PC_DXC`, `VICTORY_WARP`, `VICTORY_REF_VS`, `VICTORY_REF_PS`, `VICTORY_DEBUG_ELSEWHERE`, `VICTORY_EMIT_DUMP`, `VICTORY_PAIRS`, `VICTORY_PREBUILD_KEYS`, `VICTORY_SHADER_SOURCE_HASH`; - the D3D12 debug layer and its bits: `VICTORY_D3D12_DEBUG`, `VICTORY_D3D12_DRED`, `VICTORY_D3D12_GBV`, `VICTORY_D3D12_WARP`; - test and child-process plumbing, which arguably should not be documented as switches at all: `VICTORY_TEST_*`, `VICTORY_CASE_TEST`, `VICTORY_EXIT_CHILD`, `VICTORY_HOST_LOCK_CHILD`, `VICTORY_SAVE_*`, `VICTORY_UCRT_*`, `VICTORY_RELAUNCHED_FROM`, `VICTORY_BCPACK_*`, `VICTORY_XMA_*`, `VICTORY_TRAP_LOG`, `VICTORY_NARROW_WAVES`, `VICTORY_POKE`, `VICTORY_SKIP_CPU_CHECK`, `VICTORY_WRITE_DXIL`. Two stale names remain in `docs/native-host.md` as reported: `VICTORY_DEBUG_PS_INPUTS` and `VICTORY_TRACE_DISPATCH_INPUTS` are read nowhere in the tree.
AnastasisKon commented 2026-11-28 10:32:33 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by AnastasisKon on 2026-11-28T10:32:33Z.


Correction to the last paragraph, after reading both places: VICTORY_DEBUG_PS_INPUTS is marked "(not wired after the merge)" at native-host.md:912 and VICTORY_TRACE_DISPATCH_INPUTS is marked "(a local diagnostic)" at :1912. They are history notes that say what they are, not stale documentation, so neither needs changing. My original wording implied a defect; it does not exist.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7237963351 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/582#issuecomment-7237963351). Originally posted by [AnastasisKon](https://github.com/AnastasisKon) on 2026-11-28T10:32:33Z. --- Correction to the last paragraph, after reading both places: `VICTORY_DEBUG_PS_INPUTS` is marked "(not wired after the merge)" at native-host.md:912 and `VICTORY_TRACE_DISPATCH_INPUTS` is marked "(a local diagnostic)" at :1912. They are history notes that say what they are, not stale documentation, so neither needs changing. My original wording implied a defect; it does not exist.
AnastasisKon commented 2026-11-28 12:37:22 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by AnastasisKon on 2026-11-28T12:37:22Z.


/release - done: PR #583 documents VICTORY_LOG and the cache-keyed translation switches and closes out the inventory. In the merged fork doc the inventory now lists only the names the file genuinely does not document (VICTORY_WATCH, VICTORY_POKE, VICTORY_SKIP_CPU_CHECK, VICTORY_D3D12_*, VICTORY_WAVE32), because the rest are covered elsewhere there.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7239354141 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/582#issuecomment-7239354141). Originally posted by [AnastasisKon](https://github.com/AnastasisKon) on 2026-11-28T12:37:22Z. --- /release - done: PR #583 documents `VICTORY_LOG` and the cache-keyed translation switches and closes out the inventory. In the merged fork doc the inventory now lists only the names the file genuinely does not document (`VICTORY_WATCH`, `VICTORY_POKE`, `VICTORY_SKIP_CPU_CHECK`, `VICTORY_D3D12_*`, `VICTORY_WAVE32`), because the rest are covered elsewhere there.
github-actions[bot] commented 2026-11-28 12:37:34 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by github-actions[bot] on 2026-11-28T12:37:34Z.


Released. This issue is free to claim.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7239356359 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/582#issuecomment-7239356359). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-28T12:37:34Z. --- Released. This issue is free to claim.
Sign in to join this conversation.
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
LakshanSivakumar/Native-Victory-macOS#582
No description provided.