Docs: an index of docs/, AGENTS.md back in line with the tree, and cargo xtask docs #4451

Closed
github-bot wants to merge 15 commits from github-bot/gh-4450 into main AGit
Owner

@⁠pabloRodriguezs on GitHub · 2026-11-30 20:29 UTC · original
pabloRodriguezs:docs/agent-context → main · +1714 −900 · 41 files · 15 commits · closed without merging

What it changes

AGENTS.md and docs/ had drifted from the tree, and agents read them as ground truth. An audit on 2026-11-30 found:

  • Figures and line references out of date in AGENTS.md: victory-gpu 117K lines (now ~205K), 482 VICTORY_* switches (945), 1,233 tests (~2,700), a 640 KiB file limit (the policy says 1 MiB), MSRV 1.88 (1.89), and file:line references that pointed at the wrong code (run.rs:106, host.rs:10219, main.rs:198, …).
  • A wrong rule: "read switches only through toggled!/asked_for!". The tree has ~900 direct env::var_os reads and ~40 macro uses.
  • Two sets of defaults, documented nowhere: the layer's own defaults (what dlss.md and fork-ray-tracing.md give) and victory play's const SETTINGS. For example, VICTORY_DLSS is off in the layer and on in play.
  • No way to tell current pages from snapshots: findings.md (RX 7900 XTX, another fork) and unified-memory-audit.md (line numbers of 32ecacf) read like current reference.
  • Stale troubleshooting.md: it described the old 20-second warm-up restart, didn't mention MFG Unlocker, and contradicted linux-proton.md.
  • Broken links: nine relative links in docs/README-nvidia.md (written as docs/... from inside docs/).

Two commits:

  1. Docs. Adds docs/README.md, an index that classifies every page as reference, design note, record (a snapshot, never current) or proposal, and lists the facts several pages got wrong.

    • AGENTS.md: figures refreshed (dated, with the commands that reproduce them), symbol names instead of line numbers, the switch rule corrected, the two default layers, const KEYED. It also warns about the 1 MiB file wall: host.rs is ~924 KiB.
    • architecture.md: gains a map of victory-gpu and a Settings section.
    • troubleshooting.md, dlss.md, fork-ray-tracing.md, replay.md, README-nvidia.md corrected as above.
  2. cargo xtask docs. Checks README.md, AGENTS.md and docs/ against the tree:

    • relative links and anchors resolve;
    • repository paths in code spans exist;
    • path:N references stay inside the file;
    • every VICTORY_* name a page gives is still read by the code;
    • every page in docs/ is in the index.

    Records are exempt from the path and switch checks. repository_docs_are_consistent runs it from cargo test --workspace, as repository_passes_policy does, so CI catches drift. Its first run found one more problem: docs/bcpack.md gave another repository's fixture path as ours.

No code outside xtask changes.

Found during the audit, not fixed here:

  • The comment above SETTINGS in play.rs says scripts\play-nvidia.ps1 has the same settings, but ten of the 57 don't appear in the script: VICTORY_CARD_ALL, VICTORY_CARD_CPU_FILE, VICTORY_LAZY_COMPARE_MB, VICTORY_LAZY_NARROW, VICTORY_QUIET_WAITS, VICTORY_SAMPLED_EVICT, VICTORY_TABLE_SAME, VICTORY_TEXTURE_SOFT_MB, VICTORY_UAV_FOLD and VICTORY_WAIT_SHARE.
  • The size note in xtask/src/policy.rs is out of date.

How it was tested

  • GPU and profile: n/a (documentation and xtask only)
  • cargo clippy -p xtask --all-targets --locked -- -D warnings: clean (toolchain 1.98.1)
  • docs.rs tests: 9 passed, including repository_docs_are_consistent on this tree (docs: 31 pages ok). They ran with docs.rs built as a standalone crate on a windows-gnu host, where windows-sys cannot link. The xtask crate's own test run is left to CI.
  • cargo test passed for the crates it touches: yes for docs.rs; the full xtask run is left to CI as above

Checked for overlap

  • I searched the open pull requests for the same issue and for the files this touches. Related: #4155 (adds rules for agents opening issues and PRs to AGENTS.md; complementary, but it will conflict with this rewrite, and I'm happy to rebase onto it), #4156 (CONTRIBUTING.md), #1053 (agents guide).

🤖 Generated with Claude Code

**@⁠pabloRodriguezs** on GitHub · 2026-11-30 20:29 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4450) `pabloRodriguezs:docs/agent-context` → `main` · +1714 −900 · 41 files · 15 commits · closed without merging ## What it changes `AGENTS.md` and `docs/` had drifted from the tree, and agents read them as ground truth. An audit on 2026-11-30 found: - **Figures and line references out of date in `AGENTS.md`**: `victory-gpu` 117K lines (now ~205K), 482 `VICTORY_*` switches (945), 1,233 tests (~2,700), a 640 KiB file limit (the policy says 1 MiB), MSRV 1.88 (1.89), and `file:line` references that pointed at the wrong code (`run.rs:106`, `host.rs:10219`, `main.rs:198`, …). - **A wrong rule**: "read switches only through `toggled!`/`asked_for!`". The tree has ~900 direct `env::var_os` reads and ~40 macro uses. - **Two sets of defaults, documented nowhere**: the layer's own defaults (what `dlss.md` and `fork-ray-tracing.md` give) and `victory play`'s `const SETTINGS`. For example, `VICTORY_DLSS` is off in the layer and on in `play`. - **No way to tell current pages from snapshots**: `findings.md` (RX 7900 XTX, another fork) and `unified-memory-audit.md` (line numbers of `32ecacf`) read like current reference. - **Stale `troubleshooting.md`**: it described the old 20-second warm-up restart, didn't mention MFG Unlocker, and contradicted `linux-proton.md`. - **Broken links**: nine relative links in `docs/README-nvidia.md` (written as `docs/...` from inside `docs/`). Two commits: 1. **Docs.** Adds `docs/README.md`, an index that classifies every page as reference, design note, record (a snapshot, never current) or proposal, and lists the facts several pages got wrong. - `AGENTS.md`: figures refreshed (dated, with the commands that reproduce them), symbol names instead of line numbers, the switch rule corrected, the two default layers, `const KEYED`. It also warns about the 1 MiB file wall: `host.rs` is ~924 KiB. - `architecture.md`: gains a map of `victory-gpu` and a Settings section. - `troubleshooting.md`, `dlss.md`, `fork-ray-tracing.md`, `replay.md`, `README-nvidia.md` corrected as above. 2. **`cargo xtask docs`.** Checks `README.md`, `AGENTS.md` and `docs/` against the tree: - relative links and anchors resolve; - repository paths in code spans exist; - `path:N` references stay inside the file; - every `VICTORY_*` name a page gives is still read by the code; - every page in `docs/` is in the index. Records are exempt from the path and switch checks. `repository_docs_are_consistent` runs it from `cargo test --workspace`, as `repository_passes_policy` does, so CI catches drift. Its first run found one more problem: `docs/bcpack.md` gave another repository's fixture path as ours. No code outside `xtask` changes. Found during the audit, not fixed here: - The comment above `SETTINGS` in `play.rs` says `scripts\play-nvidia.ps1` has the same settings, but ten of the 57 don't appear in the script: `VICTORY_CARD_ALL`, `VICTORY_CARD_CPU_FILE`, `VICTORY_LAZY_COMPARE_MB`, `VICTORY_LAZY_NARROW`, `VICTORY_QUIET_WAITS`, `VICTORY_SAMPLED_EVICT`, `VICTORY_TABLE_SAME`, `VICTORY_TEXTURE_SOFT_MB`, `VICTORY_UAV_FOLD` and `VICTORY_WAIT_SHARE`. - The size note in `xtask/src/policy.rs` is out of date. ## How it was tested - GPU and profile: n/a (documentation and `xtask` only) - `cargo clippy -p xtask --all-targets --locked -- -D warnings`: clean (toolchain 1.98.1) - `docs.rs` tests: 9 passed, including `repository_docs_are_consistent` on this tree (`docs: 31 pages ok`). They ran with `docs.rs` built as a standalone crate on a windows-gnu host, where `windows-sys` cannot link. The `xtask` crate's own test run is left to CI. - `cargo test` passed for the crates it touches: yes for `docs.rs`; the full `xtask` run is left to CI as above ## Checked for overlap - [x] I searched the open pull requests for the same issue and for the files this touches. Related: #4155 (adds rules for agents opening issues and PRs to `AGENTS.md`; complementary, but it will conflict with this rewrite, and I'm happy to rebase onto it), #4156 (CONTRIBUTING.md), #1053 (agents guide). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
docs/README.md classifies every page as reference, design note, record
(a snapshot never to be taken as current) or proposal, and lists facts
several pages got wrong: the layer's defaults are not victory play's
(const SETTINGS), scripts\play-nvidia.ps1 lags SETTINGS by ten switches,
and most switches are read with env::var_os, not toggled!/asked_for!.

AGENTS.md: figures and file:line references refreshed or replaced by
symbol names and the commands that reproduce them; the 1 MiB file limit
(host.rs is at ~924 KiB); the switch-reading rule corrected.

architecture.md gains a map of victory-gpu and a Settings section;
troubleshooting.md describes the current first start (preload, not a
restart), MFG Unlocker and Linux as in the README; dlss.md and
fork-ray-tracing.md say which defaults they give; README-nvidia.md is
marked as a record and its links work from docs/; replay.md names the
tests by full path.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
`cargo xtask docs` reads README.md, AGENTS.md and docs/**/*.md and reports
relative links and anchors that do not resolve, repository paths in code
spans that do not exist, `path:N` references past the end of the file,
VICTORY_* switches no code reads any more, and pages in docs/ missing from
the index, docs/README.md. Pages the index marks as records (snapshots of an
earlier tree) are exempt from the path and switch checks. Fenced code is
skipped for links and paths.

repository_docs_are_consistent runs it from `cargo test --workspace`, as
repository_passes_policy does for the asset policy, so CI fails on it.

docs/bcpack.md named a fixture path of another repository as if it were
ours; it now says where that file lives.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-30 20:30:06 +00:00
github-bot closed this pull request 2026-12-01 18:43:37 +00:00
Author
Owner

@⁠trustno1-coder on GitHub · 2026-12-01 18:41 UTC · original

Closing this as part of moving main to the texture and video-memory rework (v2026.12.01.01-test). A lot of the code changed, and this pull request no longer applies cleanly to it; it would need to be rewritten against the new main rather than rebased. Thank you for the work. If the change is still needed, please open a new pull request based on the current main.

**@⁠trustno1-coder** on GitHub · 2026-12-01 18:41 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4450#issuecomment-7321354265) Closing this as part of moving main to the texture and video-memory rework (v2026.12.01.01-test). A lot of the code changed, and this pull request no longer applies cleanly to it; it would need to be rewritten against the new main rather than rebased. Thank you for the work. If the change is still needed, please open a new pull request based on the current main.

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/trustno1-coder--VIctory-NVIDIA!4451
No description provided.