Diagnostics: trace a DirectStorage request from submission to decoder outcome #1178
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory!1178
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-1178"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@Razdva122 on GitHub · 2026-11-24 16:21 UTC · original
Razdva122:diagnostics/streaming-refusals→main· +174 −28 · 2 files · 2 commits · openFor #1063, this adds an opt-in DirectStorage request trace. Each enqueue receives an ID that follows the request through admission, file reads and worker completion. The trace records input and destination sizes, decoder outcome, and bytes written or the failure code. The five-second throughput counters also use actual output bytes. Tests cover identical concurrent submissions, short successful output, and insufficient capacity.
On an earlier revision, the reporter traced 9,819 enqueues on a GTX 1660 SUPER. None carried 46,586 as a size, and 5,651 requests completed with 65,536 bytes written. The per-size stack capture answered its original question, so this revision removes the filter and the loader API added solely for it. The general trace remains available for other streaming reports. Reporter’s results
The README now has one row for the trace target. The diagnostic build command, PowerShell invocation and fields to compare are in the issue. Reproduction instructions
AI-assisted with Codex.
Windows CI passed both workspace Clippy configurations, the full workspace suite and the diagnostics-mode DirectStorage tests at
40dac06. Windows job · Download the Windows x64 diagnostic build@roon9e on GitHub · 2026-11-24 17:51 UTC · original
Ran the #1178 diagnostics on a reporting-class machine — the 46,586 value does not reach VIctory's DirectStorage boundary. No request matches the filter.
Setup: Windows 11, GTX 1660 SUPER 6 GB, own 1.0.2.1 copy (SHA-256
e95020b2…), Xbox Series build,win-x64,--profile diag --features diagnosticsat9b8949f, run without the localint3workaround (the stop is the raw0x80000003attitle+0x1330a44).VICTORY_LOG=info,victory_dstorage=trace,VICTORY_DSTORAGE_CALLER_SIZE=46586.Result:
source_size,destination_size,intermediate_sizeorwritten. The literal46586occurs in the log only as a substring of an offset (…4658672), never a size. The size filter therefore appended no caller stack to any request (the onlycaller=lines are the unrelateddevice slot 0x218/0x1c8warnings).options=0x1, e.g.source_size≈44k → destination_size=65536,read=source_size hr=0,completed written=65536) or raw (0x0). VIctory's side of the pair — 65,536 — is exactly what it decodes and completes.bcpack=0in every read), so the texture/BС decode is not a DirectStorage request here.So the 64 KiB/46,586 pair you were tracking does not reach VIctory's DirectStorage API as a request shape. At the same stop, reading the faulting thread's stream state directly shows where the pair actually lives:
vt[0x3f0](0x28ce0a0) is an adjustor thunk to<title>+0x28ce1b0, which searches the provider's own registry for the 64-bit interface key and thentitle+0x144db65b0reads a per-codec entry (title+0x144db6600; a0xffff/0xffentry = "absent") → returns 0 →test al,al / je → int3at0x1330a44. The provider and its registry are title code over title data (vtable in the title's.rdata), and the codec id there is0x70817.The trace is still the right instrument — it cleanly confirms VIctory's boundary is healthy and that the size pair is title-internal. What would pin it next, if useful: the same trace keyed on the codec id (
0x70817) rather than a size, or on requests whose output the title later re-reads and rejects; and a snapshot of the provider registry ([prov+0x28]→+0x20key table,+0x28/+0x38codec tables) taken while the thread is suspended. If that registry is expected to be filled from a device call, note thatdeviceslots0x218/0x1c8are currentlyE_NOTIMPL(caller="+0x24800db"/"+0x247757e", the+0x2478440bring-up group) — possible registration steps, though they also fire in every menu run.AI-assisted; run on my machine, no game data quoted.
@Zipettte on GitHub · 2026-11-24 18:00 UTC · original
Tested on AMD Radeon RX 7700 XT (RDNA3, gfx1101), driver 32.0.32029.2010, Windows 11, Rust 1.98.1 MSVC at 9b8949f:
cargo test -p victory-hle -p victory-loaderpasses, 121 passed / 0 failed. Workspace baseline on main (ffe310e) is green on the same machine (342 passed).Tested with AI assistance (Claude).
@Marvisak on GitHub · 2026-11-25 01:18 UTC · original · edited 2026-11-25 16:01 UTC
Automated triage for the maintainers.
This pull request no longer merges cleanly into
main(conflicts incrates/victory-hle/src/modules/dstorage.rs). It will be reviewed once it is rebased onto the currentmain. The earlier verdict (merge-candidate) was for an older state ofmain.Generated by Claude Code
@Razdva122 on GitHub · 2026-11-25 06:55 UTC · original
@Marvisak, could you re-review
f475df1and update thetriage: needs worklabel if the revised scope addresses your feedback?The reporter found no request carrying 46,586 as a size across 9,819 enqueues. I removed the size filter, the caller-stack capture and its loader API. The general request ID and actual bytes written remain available. The README now has one row for the trace target, and the reproduction procedure is in #1063.
Both Clippy configurations, the workspace suite and the diagnostics-mode DirectStorage tests passed on Windows. Changes since triage · Windows CI
f475df13acto40dac069cb@Razdva122 on GitHub · 2026-11-26 12:28 UTC · original
Could you re-review the DirectStorage trace at
40dac06and refresh the rebase label? The branch now merges cleanly withmainat63bcca4and keeps the upstream request-admission changes. Both Clippy configurations, the full workspace suite and the diagnostics-mode DirectStorage tests passed on Windows. The diagnostic build in the PR description has also been rebuilt at this commit. Windows verificationView command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.