Faces move: d16 accesses ask for the kind of a view in a table too; victory replay --bytes #114
No reviewers
Labels
No labels
accessibility
already-solved
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
merged
needs-decision
needs-game-run
needs-rebase
not-merged
nvidia
obsolete
question
security
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/avatarmanz--VIctory-7900XTX!114
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-114"
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?
@secure-silicon on GitHub · 2026-11-26 04:05 UTC · original
secure-silicon:faces-and-replay-bytes→main· +129 −7 · 7 files · 3 commits · openSummary
Faces stood still (lips, brows, blinks) while bodies, hair and cloth moved. The face network keeps its 16-bit halves in views of integer formats (
R16_UINT), in tables, and reads and writes them with_d16accesses. The translator asked for a view's kind only of views a program picks from the heap, so for these it took the halves as f16 through a float view: an integer's bits as a float are a denormal, whose f16 is zero. The network's result was all zeros, which is a face at rest.The network's tables hold constant buffers, so the host always makes them afresh in dynamic slots; those slots had no word before.
Second commit, a tool that found it:
victory replay <capture> --bytes <resource>[:<at>:<bytes>]prints what a capture holds of a buffer (contents at the frame's start, what the CPU had changed by each submission, how many dwords are not zero), read from the capture's files with no device made.Evidence
CS_BlendshapeTranslationsHSSGraphOutputExtractreads the network's result from held nothing but zeros, while the network's weights and the extract's other inputs were there. The translatedCS_GatherOperation, which writes that result, hadlegacyF32ToF16on all 31 of its loads and no read of the table of strides.After: faces move in the same cutscene, on an RTX 4080 SUPER (one run, on a tree with the same change). Not yet seen on an RX 7900 XTX.
cargo test --locked -p victory-shaderon this branch: 278 passed, 4 ignored.cargo check --locked --profile diag -p victory --features diagnosticspasses.Details are in
docs/findings.md("Faces stood still").Merge Danger
Door: two-way
Two small commits, reverted independently. The translator's sources change, so the shader cache translates every program again on the first run.
Blast Radius: translator
Every program with
_d16typed accesses to views in tables now has the root view of the table of strides, so binding one asks for the heap pass (once a frame), as programs that pick views from the heap already do. A typed store onto an integer view still goes through a float handle and relies on the driver passing the bits, as it already did for views picked from the heap.🤖 Generated with Claude Code
@avatarmanz on GitHub · 2026-11-26 07:39 UTC · original
Left open: d16 accesses through table views change translation on every card (and the PR notes faces not yet seen moving on the 7900 XTX); needs an in-game check there first.
@FrozenGuy7 on GitHub · 2026-11-26 09:53 UTC · original
Confirmed on AMD: with this PR, faces move (lips, brows, blinks) in cutscenes and close-up dialogue on an RX 9070 XT (RDNA 4). Without it, on the same machine and save, faces stayed at rest while bodies, hair and cloth moved.
9576c45+ this PR (41f93b7,8003422),--profile diag --features diagnostics, plus local merges of #55, #53 and #28 (needed on RDNA 4)scripts/play.ps1 -Safe, FSR 4.1.2 + Frame Generation 4.0.2,VICTORY_PORT_CONSTANTS=1,VICTORY_PORT_DESCRIPTORS=1victory shaders: 25,790, 195 left) andvictory warm: 88,752 pipelines made, 0 compiler crashesOne note for whoever merges this together with #55. #55 reads a view's record count from the table of strides (its
SLOT_COUNTS_ATpart) for views in tables too, not only for views picked from the heap. But the host writes those counts only for title slots, so a view in a table made afresh in dynamic slots reads 0 records. This PR'sHostHeap::dynamic_wordis the natural place to write them. Locally I write the count there as well (counts + index ← view_records(view)), next to the stride/kind word. Without #55 it doesn't matter.(Tested by me; the merge, the build and this write-up were done with the help of an AI assistant, Claude.)
@bordersky on GitHub · 2026-11-26 10:23 UTC · original
Tested on Linux: RX 7900 XT, RADV through vkd3d-proton master, GE-Proton10-34's Wine, on main
9576c45. This tree also carries fxceless#927's half views for table views, sointeger_viewthere is asked only for views that do not move halves.What #114 changed here is the word a table view now has. That word is what Beqren's raw typed loads (from #129,
1711cd1c2) check before reading raw:VIEW_INTEGER | 2*count.This is the player's observation in the prologue, without a capture. Two things are not separated: #114's own
integer_viewpath, and the raw loads it lets through.@UwUCammie on GitHub · 2026-11-26 11:29 UTC · original · edited 2026-11-26 22:14 UTC
I isolated the renderer and translator changes in
41f93b7eon the Linux Radeon branch, with the bounded compute wait in both builds. Same saved data, Series X, RX 7900 XT, RADV 26.3.1, Wine 11.22 and vkd3d-proton GE buildcae8353e(reported version 3.2.0). Each run started from its own copy of the same caches with source-keyed translations. Both reported just over 19 GiB of local budget at startup.In 24 Hz recordings of the seated character turning back toward the server, the control kept the lips close together. With the table-kind change the jaw and lips moved, but the upper lip pulled up toward the nose and left a large opening. Both builds drew the facial skin. So I can reproduce a change in facial movement with #114 alone on this card, and the deformation remains on this combination. These two builds do not include #927 or the guarded raw typed loads in bordersky’s tree.
Two d16 paths covered by the new game-free test · Radeon test source
@towade on GitHub · 2026-11-26 13:54 UTC · original
Tested together with #55 on an RX 9070 XT (RDNA 4), Windows: mouths move only with FrozenGuy7's record-count note applied
Hardware: Radeon RX 9070 XT 16 GB, driver 32.0.32029.2010 · Core i7-14700K · 64 GB · Windows 11 26300. Base:
9576c45+ #55 (without it this card does not get into the world) + this PR at6170882,diag, all 25,790 shaders translated ahead,scripts\play.ps1with defaults. Same cutscene before the boat both times.dynamic_wordalso writing the record countFor the second row I followed FrozenGuy7's note above: with #55, a view in a dynamic table slot reads 0 records unless
dynamic_wordwrites the count beside the stride. My change, incrates/victory-gpu/src/descriptor/host.rs:plus a
TRANSLATOR_VERSIONbump so the cache is rebuilt. Tests (victory-gpu,victory-shader) pass with it. So if #55 and this PR both land, the one that lands second needs this, or faces stay still on cards that take #55's path.Two more things, which I cannot pin on this PR yet (no A/B without it so far):
0 first-chance exceptions; the second run went about 70 minutes without a crash.
AI-assisted (Claude Code).
@Fedalv on GitHub · 2026-11-26 18:11 UTC · original
RX 7900 XTX (RDNA 3), Linux/Proton: this PR alone tears mouths; with fxceless#927's half views and the raw typed loads faces are right
Same as UwUCammie saw on the 7900 XT, now on a 7900 XTX: Linux, Mesa RADV 26.2.5, Proton Experimental 11.0-20261112 with vkd3d-proton master
71cae09, mainc9c932c(later2de9980), Series X, all shaders translated again for each build. Opening cutscenes (interrogation close-ups, the boat), compared by eye in captured frames; no captures posted (asset policy).c9c932cfrom its diff against9576c45)So on RDNA 3 this PR is half of the fix: it makes the face network compute, and the other two pieces make what it computes right. For #231 that also means the flat eyes come from the same zeros, not from reflections. The three together apply cleanly onto current main (
victory-shadertests: 209 passed); the only conflict on rebasing isTRANSLATOR_VERSION.AI-assisted (Claude Code); runs on my machine.
@flamme-demon on GitHub · 2026-11-26 22:05 UTC · original
Tested and working here (eyes), together with fxceless/victory-fork#927's half views and the raw typed loads, taken from bordersky/victory-linux's tree as Fedalv describes above. That set applied onto
c9c932c+ the Linux PRs below without a conflict;victory-shadertests: 209 passed. All shaders translated again (its translator version), pipelines warmed again.Setup: RX 7900 XTX (RDNA 3), Mesa RADV 26.2.4, Proton Experimental 20261112 with its wineserver rebuilt with the view tree, vkd3d-proton master
71cae09, Microsoft'sd3dcompiler_47; mainc9c932c+ #151, #166, #200, #201, #274; diagnostics build, Series S (VICTORY_UPSCALER=6). Linux runs in a KVM guest with the card passed through.Tested by Claude Code (Claude Opus 5.5) on my machine; I only watched the picture. No captures posted (asset policy).
@borntofrag34 on GitHub · 2026-11-27 09:23 UTC · original
Tried on an RX 7900 GRE under Linux (RADV 26.3.1, vkd3d-proton 3.2.0, Proton Experimental's Wine), since the description says it was not yet seen on a 7900: the two commits picked onto the Linux branch of #440 (same base,
c9c932c), every shader translated again, one run each, the opening cutscene's shot where both raise their hands, frames kept every eighth frame and cropped on the faces.title buffer 0xda62c8580+0x104000) is all zeros on the card and in the copy of title memory, as described here41f93b7,8003422)32a7e6f: d16 image bits, NaN guard, early depth, strict spills, all at their defaults)bufferLoad.i32/bufferStore.i32, props 0x405, chosen at run time by the same word of the table of strides) instead of the float handleSo the network no longer gives zeros here, but not the right values either. The last row was my first suspect (the note that a typed store onto an integer view goes through a float handle and relies on the driver passing the bits): it is not that, the picture does not change. What it is has not been found yet; I am going on with a recorded frame and the network's programs one by one, and will report here.
🤖 Generated with Claude Code
@borntofrag34 on GitHub · 2026-11-27 09:38 UTC · original
Follow-up on the RX 7900 GRE under RADV (same tree as above: this pull request and #329's shader commit on the Linux branch of #440). Three more things tried, one run each, none changes the picture (mouths agape, changing a little from frame to frame):
VICTORY_HOST_WAVE=32), as on the RTX 4080 SUPER;VICTORY_RDNA_FLOAT=0), so the same operations as on other vendors' cards.From a frame recorded in that shot (two faces): the network's list runs 369 dispatches of 14 programs, and the buffer the deformer reads its result from (
title buffer 0xda62c8580+0x104000, R16_UINT) holds 100,533 halves in one stretch, no NaN and no infinity, between -0.054 and 0.026 as f16 (mean magnitude 0.003), the first vertices some 4 cm away from rest; only 40 of its dwords changed in that frame. So the network gives numbers of a sensible size here, of a jaw wide open, and nearly the same from one frame to the next.A question that would help to tell a difference between cards from something still missing: on the RTX 4080 SUPER, are the mouths right while people speak (closed between words, following the lines), or do faces move without matching the speech? If you have a frame captured there, the range of that buffer's halves would be enough to compare.
🤖 Generated with Claude Code
@borntofrag34 on GitHub · 2026-11-27 13:23 UTC · original
Result on the RX 7900 GRE under RADV, as promised above: with the other two pieces Fedalv names, mouths are right here too.
Taken together as bordersky/victory-linux carries them (its tree at 2294b83 against main
9576c45, the translator's and the descriptors' files only: this pull request, fxceless/victory-fork#927's half views, and the raw typed loads), onto the Linux branch of #440. It applied without a conflict; every shader translated again.Two runs (100 s and 200 s: the street, the police stop, the car), frames kept every eighth frame and looked at; no captures posted (asset policy). The frame is as long as before: 28.9 ms against 28.8 over the same stretch.
So the same as on the 7900 XTX: on RDNA 3 under RADV this pull request is half of the fix. What I tried before and can now set aside as causes: integer handles for d16 typed accesses, waves of 32, the RDNA float shortcuts; and RADV's two compilers (ACO, and
RADV_DEBUG=llvm) give the network's result word for word the same, so it is not the driver's compiler either.It is in #440 now (
542d441, with the authors named).RX 7900 GRE, RADV 26.3.1, vkd3d-proton 3.2.0, Proton Experimental's Wine, Series X at 1920x1080.
🤖 Generated with Claude Code
View 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.