AMD (RDNA4, RX 9060 XT): null read inside amdxc64.dll while world PSOs compile; VICTORY_SHADER_OPT=0 avoids it #881
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/fxceless--victory-fork#881
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
@Chuantao717 on GitHub · 2026-11-25 11:38 UTC · original
AMD (RDNA4, RX 9060 XT): null read inside amdxc64.dll while world PSOs compile; VICTORY_SHADER_OPT=0 avoids it
First: this fork got the game's world and its opening cutscene rendering on my AMD card, which upstream VIctory could not (upstream loses the device right after the account/PLAYER screen here). The running frame shows the prologue interior cutscene at ~1 fps, so the render work itself clearly works on RDNA4.
Environment
mainwithcargo build --release -p victory(rust 1.98.1-msvc), 0 missing imports on the title executable and its 4 sidecar DLLsvictory.tomlpointing at the game folderCrash 1 — default switches, ~4.5 min in, during the opening cutscene
It is a null read inside AMD's own DXIL compiler, reached from
D3D12Corewhile a pipeline is being created. Frame log just before it: ~2 s/frame, ~4500-5400 draws/frame.Crash 2 —
VICTORY_SHADER_OPT=0With the new shader clean-up passes disabled the run survives far longer (14 minutes vs 4.5) and plays through to the opening credits and the in-car / apartment cutscene shots. It then stops on a guest
int3rather than the driver:(RVA 0x5149aec, image base 0x140000000.) That looks like a title assert after the cutscene hands over, i.e. the known first-room problem, not a driver fault.
Why I think the amdxc64 crash is worth reporting to AMD
The same adapter/driver crashes with the same signature in an unrelated translation layer on this machine (PercyScarlett, a different clean-room project:
amdxc64.dll+0x1aab91c, null read, also during the first world PSO compilation). Two independent DXIL producers, one driver component, same symptom on RDNA4.If
VICTORY_SHADER_OPT=0is really what avoids it, the trigger is plausibly a DXIL pattern produced by the new clean-up passes (dead-code elimination / constant folding / value reuse / branch facts) thatamdxc64mishandles. Two things that would help a lot:D3D12CreatePipelineStatewhen this happens (VICTORY_EMIT_DUMP/VICTORY_SHADER_SAVE?), so the offending module can be reduced and attached to an AMD bug report.VICTORY_SHADER_OPToff on AMD adapters, or retrying a pipeline once with the passes off when pipeline creation faults, so RDNA users keep moving.Speed data on this card (for the record)
VICTORY_SHADER_OPT=0VICTORY_SHADER_OPT=0 VICTORY_RELAY=2 VICTORY_LATE_WAIT=3 VICTORY_WIDE_BACK=1 VICTORY_CARD_BUFFERS_MIN_MB=1 VICTORY_CARD_BUFFERS_MB=1024So the newer switches are worth roughly 2-4x here, but the card is still the limit and prepare still dominates. No device loss and no driver hang in any of these runs — that is already much better than upstream on this machine.
With the switches combined the run lasted ~19 minutes and ended on a second, different guest assert rather than the driver:
That is RVA 0x63966f (image base 0x140000000), some minutes after the in-car / apartment cutscene shots, so the cutscene-to-gameplay handover looks like the next wall on this configuration.
Crash context from the game's own crash dumper (new)
Both guest
int3runs leavevictory-*.crash.login the T: temp folder. The two dumps agree:fbk_stry000_FBK_STRY000_INTROSo both asserts fire while the intro scene is still Prestream, at the moment the cutscene hands over to the world,
with the instance-list pool at its ceiling and building/object pools near theirs.
Static analysis of the two
int3sitesNeither is a compiler-inserted
__debugbreakin the middle of a function. Both are cold "unreachable" blocks:0x5149aeclives in function0x5149980-0x5149b04, a lock-free fixed-size allocator: free-list head at+0x20(
lock cmpxchgloop, 17-bit index mask0x1ffff), backing table at+0x0, and four branches that jump to theint3: head ==0x1fffe(twice) and backing pointer == NULL (twice).rax's low half was0x0001fffe, i.e. the sentinel branch was taken: the allocator had no freeentry (or an invalid state) and the title treats that as unreachable.
0x63966fis the same shape at the end of0x6395d0-0x639674.Together: an allocation out of the fixed-size pool hits an "impossible" state and the title breaks. That fits the
INSTANCE_LIST at 45000/45000 in both dumps — the pool that runs out is plausibly the instance list itself while the
intro scene streams in, i.e. the fork is asking for (or failing to release) more instances than the console would.
Happy to run any diagnostic build, dump shaders, or test a patch on this exact RDNA4/driver combination.