NVIDIA: view-heap slots past 737,855 are never mirrored (driver caps heaps at 1,000,000); phone screen black (separate cause: exposure texel stuck at -10) #545
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/trustno1-coder--VIctory-NVIDIA#545
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?
@chemist6913 on GitHub · 2026-11-28 00:38 UTC · original
Summary
On NVIDIA, every view the title places in its view heap at a slot past about 737,855 reads the wrong descriptor, or a null one. Shaders that pick descriptors by index (bindless) are hit; tables are not. The visible case is the cracked phone in the opening diner cutscene: its screen should show the ride app's "account suspended" page under the cracks, but it is black in most runs. It lit once for a whole run, and sometimes for a moment while the scene loads.
Seen on an RTX 5090 (driver 621.40, Windows 11), Series X profile, 1440p, on current
mainplus local diagnostics. The heap cap below should apply to every NVIDIA card, so other bindless materials past that slot are likely wrong on NVIDIA too.Cause
HostHeap::newtakes thePORTABLE_VIEWSpath:DYNAMIC(2^18) per-draw tables;umin(index, 999999).changed_slotsstops atmirrored_count, andmirrorreturnsNoneforindex >= count. The comment there already says "a title that reaches them needs remapping".The phone, step by step
909d7b7af414d9e0(PS_DeferredTextured_c5fd36bb) with mesh shader5cbcffe7dfa18da4.movie colour × lerp(1, T·K, C) × s:sis a packing constant, 1/256;Tcomes from a small 4×4 BC1 texture named by the material record;C(cb[2].w) andK(viacb[6].y) are read from a constant buffer at heap slotu10 >> 5.TL_PS_NoDir_PBR_MATERIAL_EMISSIVE_DIFFRACTIONand the plain emissive variant) decode it correctly;-Fastand the shader optimisation level change nothing.How the title uses the heap (census, opening cutscene)
I counted the records holding a view in each 64K slots of the title's heap, in three frames running, every 600 frames. Frame 1200:
From one frame to the next, almost nothing changes (0–28 records per 64K). So:
slot mod Mwould let two live views share a host slot, because one frame's records lie across the whole range.Proposed fix
A remap of title slots past the mirrored range:
>= countthat gets a view is given a host slot from a pool. The pool would be the identity slots the title leaves empty, or a fixed region taken from the mirrored range. The slot is freed when the title clears the record or writes over it. Its descriptor is made there, through the samemirror/ buffer-pass path as any other slot, keyed by the title slot.u32per title slot (5 MB), identity belowcount. Shaders read it like theSLOT_STRIDESroot SRV, only for indices>= count, so slots below it cost nothing extra.heap_handle_at:index < LIMIT ? index : remap[index], in place of theuminclamp alone.I'm working on this in my fork and will open a pull request once it is verified over several diner runs. I'm posting now in case someone has a simpler route, or another NVIDIA bug with the same cause.
Diagnostics used (all behind
--features diagnostics)VICTORY_VIEW_SIZES=1: logs which view-heap sizes the driver accepts.VICTORY_HEAP_CENSUS=<frames>: the census above.I can share any of these.
@github-actions[bot] on GitHub · 2026-11-28 00:38 UTC · original
Please attach both logs from the run that went wrong. Without them we can only guess. Paste
%LOCALAPPDATA%into the address bar of File Explorer to get there.%LOCALAPPDATA%\victory\logs\: the newestvictory-nvidia-play-<date>-<time>-<number>.log(fromvictory.exe) orvictory-nvidia-<date>-<time>.log(from the script launcher). The window shows its path at the start, on the lineLog: ....%LOCALAPPDATA%\VIctory\data\7952987A\crashes.log, and, if there is one from that run, the newestvictory-<date>-<time>-<number>.crash.login%LOCALAPPDATA%\VIctory\data\7952987A\temp\.Also say which GPU, Windows version (10 or 11)
@chemist6913 on GitHub · 2026-11-28 00:47 UTC · original
Not a crash: the game runs; the phone screen in the diner is black. RTX 5090, driver 621.40, Windows 11 Pro (build 26300), Series X profile, 1440p, diagnostics build. Key lines from three short diner runs below (full logs on request; they are 2.5 to 5 MB each).
Run vs1: which shader-visible view-heap sizes the driver takes (
VICTORY_VIEW_SIZES=1)Run mb1: the phone screen's material constant buffer slot (
u10 >> 5), logged at its draw (first 12 of the 28 such lines)Run hc1: census of the title's view heap (
VICTORY_HEAP_CENSUS=600; per 64K slots: views, constant buffers among them, records changed since the census before)NVIDIA: view-heap slots past 737,855 are never mirrored (driver caps heaps at 1,000,000); black phone screen in the dinerto NVIDIA: view-heap slots past 737,855 are never mirrored (driver caps heaps at 1,000,000); phone screen black (separate cause: exposure texel stuck at -10)@chemist6913 on GitHub · 2026-11-28 01:24 UTC · original
Correction: the heap cap is real, but it is not why the phone is black.
I built the remap described above. Title view slots from 65,536 on now get a host slot from a pool of 672,318, through a table the translated shaders read. Slots are given back when they are made null.
cb[2] = 1,1,1,0,cb[6] = 0,0,-0.3,1), and the screen is still black. So that buffer was never the cause.What actually decides the screen
In the pixel shader, the G-buffer alpha gets its emissive bit (+32) only when
On the card, that texel is
[0.0009765625, -10, -10, 0], i.e. 2^-10 with a log value of -10. Both of the textures that take turns per frame hold exactly that. With it, the screen would need a luminance of 256.It looks like an exposure value stuck at the floor of a log-luminance clamp. The title's own memory for the texture is zeros. No recorded op in the captured frame writes the texture.
Not the writer:
VICTORY_RECT_HALF=1: no change);VICTORY_LEAVE_OUTpasses.Next: find which pass writes that texture on the console, and why its input is dark.
Whether the remap is worth a pull request on its own (every bindless read past slot 737,855 is null on NVIDIA without it) is a separate question. I'll test its frame-rate cost first.