NVIDIA: Xid 109 device loss and direct-indexed compute dispatches skipped (RTX 3080 Ti, main c6ce497) #232
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?
Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-26T13:53:52Z.
NVIDIA: Xid 109 device loss and direct-indexed compute dispatches skipped (RTX 3080 Ti, main
c6ce497)Two-hour ProjectScarlett run on an RTX 3080 Ti (driver 620.70.06, GE-Proton11-14, Bazzite), main at
c6ce497plus #225.Device loss: after about 2h40m vkd3d-proton reported
VK_ERROR_DEVICE_LOST. The kernel loggedNVRM: Xid 109, name=game_scarlett_m, errorString CTX SWITCH TIMEOUT. That's a context that couldn't be preempted, rather than an Xid 13 fault like Nick's. One candidate: the translator's state-machine watchdog allowstb_guard++ < 1000000uiterations, so a translated spin wait on memory that never changes could hold the GPU far past the switch timeout. VItoriaBr caps shader loops at 4096 for this reason. I haven't confirmed which dispatch was running.Skipped work (from #223's reason text): 19 skips, all
its root indexes the resource heap directly:0x248cbc1 and 0x2951ba match NickStallman's 5090 runs. Reading
reflected_rootincompute_table.rs, a compute root only gets a reflected layout with one or two leading tables (simple), or at least one table followed by constants and descriptors (extended). A bindless root with no tables (root constants plusCBV_SRV_UAV_HEAP_DIRECTLY_INDEXED) matches neither, so it returnsUnsupported, and with an arena active every dispatch is skipped. If that's the shape here, accepting zero-table direct-indexed compute roots would bring these dispatches back, since the translated programs already carrytb_heap_map. Happy to write it if that matches your understanding of the layout.Also seen: 1,297
vkd3d_compile_shader_stage ... result -3(up from a handful in earlier runs), one list rejected withplaced texture publication failed: HRESULT(0x80004005), 3 memory waits released, 7 signaller timeouts.Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-26T14:24:41Z.
Yes, that matches what I see, so please go ahead; I won't start on it. On the RTX 5090 the same two callers (0x248cbc1 and 0x2951ba) account for most of the ~1,000 skips per world frame, from before #223 existed. I can run the change on the 5090 past the story intro once it's up.
On the device loss: my second #216 run (PR head
7e0ad65plus #217, RTX 5090, 595.99.02) also ended inXid 109 … CTX SWITCH TIMEOUTat Prestream Metadata, about 19 min in. The first ended inXid 13 … SKEDCHECK36_DEPENDENCE_COUNTER_UNDERFLOW. Neither had a breadcrumb dump (VKD3D_CONFIG=breadcrumbsprinted nothing), so I can't confirm thetb_guardtheory either, but a translated spin that outlives the preemption timeout would fit the 109.Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-26T14:51:31Z.
@NickStallman draft is up as #235 : table-less, heap-indexed compute roots now get a reflected layout with the index map as a root SRV, and the translator already reads it through tb_heap_index. Would be great to see whether the 0x248cbc1 / 0x2951ba skips disappear on the 5090 past the story intro. I'll add a Lanes scenario next.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-26T17:50:46Z.
A lead on the Xid 109, from one run on an RTX 5090 (595.99.02, GE-Proton11-14,
main3b8a220, providers redeployed and hash-checked this time):CS_RaytracingResolve; the rest are a handful each ofCS_DenoiseShadowMaskPoissonDisc*,CS_VirtualTable_SortJobsand others. Most of their loops end only at the generic guard (++tb_guard < 65536u, or the dispatcher'stb_guard++ < 1000000uinhlsl/emitter/control_flow.rs).null_compute, matching by source digest; 53 of them were created in this run) and left everything else unchanged.0x98c85f2aset at frame 3,822, intro SRL atPrestream, 20–30 fps.Xid 109 CTX SWITCH TIMEOUT(onceXid 13).GPU memory wait released after 5s(target0x1f90a), then the watchdog.This is one run, so it's suggestive, not proof. If the resolve kernels are the cause, the likely mechanism is a data-dependent loop running to its guard on bad inputs, which at 4K is far beyond the preemption window. I can share the hash list (
source digestprefixes) or run a narrower split, for example only the 206 resolve kernels, if that helps whoever picks this up.Imported from brcly/TuxBox. Originally posted by Valdi320 on 2026-11-26T18:53:17Z.
@NickStallman thank you for the narrowed 235-program experiment. I found two offline replay bugs affecting .wave32 archives and corrected them in https://github.com/brcly/TuxBox/pull/261. It also adds a CPU-only guard census:
python tools/audit_shader_guards.py REQUESTS --baseline OLD_XSHADER --candidate NEW_XSHADER --json guard-summary.json. Both sides use identical private digest-verified inputs and the actual variant flags. This should help separate newly admitted compute with generic guards from the rest without exposing title inputs. Static guard presence does not establish a spin or device loss. If convenient, please share the aggregate for the 235 requests or the non-sensitive digest prefixes you offered, and the narrower resolve-only result if you run it. #259 independently prevents a fence worker from waiting forever for a notification after reported device removal; it does not fix the Xid or dependency cycle. I do not have the 235 actual requests locally.Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-26T22:31:22Z.
Still happening on current
mainon driver 620. On an RTX 5090, driver 620.70.10 (open kernel module), GE-Proton11-14, I ranmainate76ff6aplus #235 with warm translations. It reachedGame Runningwith SRLfbk_stry000_FBK_STRY000_INTROin statePrestream Metadata, frame 26,182, about 11 minutes in. Then it hit:vkd3d-proton then reported
VK_ERROR_DEVICE_LOST, and the game exited with code 5.It's the same point as before, and #235, #254, #260 and #269 didn't change it. Earlier, swapping #216's newly translatable compute programs for no-ops got past this point; that run then stalled as in #215. I'm repeating that with the no-op list on current main to see whether it still holds.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-27T01:31:14Z.
These are the programs skipped right before the Xid 109, from a probe run on
maine76ff6a+ #235 on an RTX 5090 (620.70.10). The run is named in the probe output; there was no null-CS list, and the hang came about 7 s into the intro world.All were translated, then skipped at dispatch with
pipeline has no paged descriptor layout: its root indexes the resource heap directly. Each root has the direct-indexed flag (0x400; six also have 0x800) and at least one descriptor table, so #235's table-less path doesn't cover them.Another 37 skipped pipelines were stand-ins.
What this suggests (inferred, not proven): the skipped set includes the writer of indirect dispatch arguments and the programs that clear and accumulate count buffers. The same run made 268 distinct
ExecuteIndirectdispatches. An indirect dispatch that reads an argument or count buffer nobody wrote runs with whatever is in that memory, which fits a context-switch timeout. It also fits the earlier result: replacing heavy consumers such as the ShadeVerify and resolve programs with no-ops postpones the hang, but doesn't remove it.Two fixes follow:
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-27T02:38:56Z.
Conclusion from a series of RTX 5090 runs (620.70.10, GE-Proton11-14,
maine76ff6a+ #235 and 12e4b06/d8c4327): the early Xid 109 follows a half-translated chain. The producers of the ray-tracing and irradiance-cache passes are stand-ins that write nothing, and the consumers after them run for real, throughExecuteIndirect, on data nobody wrote. Making those consumers no-ops is the only change that moved the hang.A local probe named each compute program at dispatch, each skip, and the program behind each stand-in. The skipped programs are in my earlier comment.
Measured
CS_Alpha_Schedule,CS_VirtualTable_SortJobsas no-opsCS_RaytracingResolvekernels as no-opsExecuteIndirectThe six:
CS_Primary_ShadeVerify(214ec2b4),CS_IrradianceCache_ShadeVerify(0fd5a201),CS_Primary_UpdateVirtualTable(6db0122e),CS_IrradianceCache_UpdateVirtualTable(0c40c71f),CS_Primary_ConsumeProbeShadingSignal(cfd66765),CS_IrradianceCache_ConsumeProbeShadingSignal(104a3aab). The seventh,CS_ShadowRenderTiledCascadesCBPPPC, is a stand-in anyway.31 stand-ins in the first seconds of the world, grouped:
CS_IrradianceCache_GatherVBuffer_WithFar,_Shade,_ShadeSecondary,_ShadowTrace_WithFar,_RegisterShadowTraceRequests,_IntegrateIrradianceSH;CS_Primary_GatherVBuffer_WithFar,CS_Primary_Shade;CS_ShadeAlpha,CS_GatherAlphaVBuffer_WithFar.CS_RaytraceVBuffer_RayBinning_ShaderBinning_Mixed_WithFar,CS_ScreenProbes_TraceRays_RayBinning_BVH_Mixed_ShaderBinning_WithFar, fourCS_RTDistantShadowTrace*32_Tiled,CS_ComputeInfiniteRRIntensity.CS_RaytracingResolve, twoCS_DummyResolve.CS_ShadowRenderTiledCascades*,CS_ShadowRenderTiledMiscCBPPPC.CS_ProjDecal*,CS_Tree_BatchCull.Why they have no translation, from the translator's recorded refusals for those requests: 23 are wave or lane semantics (14 "wave reduction … divergent control flow" and variants, 4 non-constant lane operands, 2
v_readlanein a non-uniform loop, 2 unverified EXEC election, 1 needing complete 64-lane waves), 4 are BVH traversal, 3 are other (s_setpc, an unresolved image descriptor, a swizzle in a loop), and 1 has a translation but still got a stand-in.Indirect arguments are not the early hang. A second probe found no indirect record over the limit (largest 573 groups) and no hoisted count-buffer fetch. The last new program before the stop was
CS_Primary_UpdateVirtualTableat (27,1,1).Two real bugs turned up on the way and get their own PRs; neither cures this hang:
CS_RaytracingResolve) run with zeroed root constants when the runtime appends a private root SRV.INDIRECT_ARGUMENTtransition. A Lanes scenario reproduces it on this card in 48 of 48 rounds.Inferred
What it suggests
A stand-in for a producer leaves its consumers live. Holding those consumers back, or much lower loop guards, would bound the damage until the producers translate. Most of the 31 are refused for wave and lane semantics, so that is where translating them starts.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-28T05:07:47Z.
Progress on the RTX 5090 hang. Measured unless marked.
Where the hang was. We built vkd3d-proton (
cae8353e, the commit GE-Proton11-14 ships) with breadcrumbs enabled; the shipped build has them compiled out. One run's device-lost report put the unfinished work in 39ExecuteIndirectmesh draws on the direct queue, with no compute in the region. Every shader hash in the region maps byte for byte to a cached translation. Four of those mesh programs vote across the group's two 64-lane guest waves inside a loop whose exit each wave decides for itself. When the trip counts differ, one wave reaches group barriers the other never does. These loops also had no iteration guard.#372 makes such loops run as a whole group: a group vote decides the exit, finished threads skip the body but still reach every barrier, and every mesh loop is bounded.
Game runs on a warm cache, all reaching the story load:
main: Xid 109 in four runs.mainplus #372: no Xid 109 in one run. About 14 minutes in it got an Xid 31 instead: a front-end write fault to an unmapped address (HUBCLIENT_FE … FAULT_PDE ACCESS_TYPE_VIRT_WRITE).The new fault (inferred). It came 7–12 s after vkd3d-proton dropped 123 raytracing builds ("Failed to place destAccelerationStructure") and 97 postbuild-info writes ("Invalid resource"), because their title addresses map to no resource. VRAM had also just filled. The provider passes some of those title addresses to vkd3d untranslated. #320 covers that, and we are running #372 with #320 next.
Earlier leads, now set aside
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-28T07:00:02Z.
Update: on the RTX 5090 (620.70.10), ProjectScarlett has rendered the story's opening world scene for the first time in our runs, after the "Vice City, Two years ago" card. It's a night skyline seen past a fence and an overhang.
It ran at about 17 s per frame with the GPU at 100%, then about 6 minutes in raised a cascade of Xid 13 (SM MMU faults), followed by Xid 109 and Xid 31.
The build that got there:
main(7bafe6b6) plus:What each fix changed, one fault at a time (traced with vkd3d-proton breadcrumbs and
VKD3D_CONFIG=fault):RehydrateRaytracingAccelerationStructureBatched2X, at least 256 per scene). TuxBox answers that call withE_NOTIMPL, so the TLAS keeps raw addresses. Details are on #320. We're writing the rehydrate-as-build fix on top of #375 and #376.Still open: the slow frames, and the remaining Xid 13 cascade. One more thing we measured: most DirectStorage reads into physical pages fail, because the page entries we read are 0 ("page never issued"). That's being traced.
Imported from brcly/TuxBox. Originally posted by 1093i3511 on 2026-11-28T13:13:17Z.
An AMD data point for the world-entry hang. On RDNA2 it is still there after the fixes you list, and without any fault.
Setup: RX 6600 (
1002:73ff, RDNA2, 8 GB), Mesa RADV 26.3.1, Linux 7.3.6, GE-Proton11-14 (stock vkd3d-proton, no breadcrumbs), Microsoft DXC 1.9.2609. ProjectScarlett 1.0.2.1, offline, 3840x2160, warm shader caches. All builds below aremainb426c1aor later, so #372 is in each of them. Details of the individual runs are on #320 and #394.Five runs, four builds, same place
Every run reaches world entry: the title sets mission
0x98c85f2a, and the run ends 4 to 6 frames later.mainb426c1a(2 runs)PERMISSION_FAULTS: 0x3), then compute and gfx ring timeoutsSo on AMD the same sequence you found on the 5090 shows up:
What's left is a gfx ring timeout with no page fault and no MODE1 reset (
ring gfx_0.0.0 timeout ... Ring gfx_0.0.0 reset succeeded, thenVK_ERROR_DEVICE_LOST). It doesn't depend on the acceleration structures: it happens with all of them dropped and with all 256 built. #373 didn't change it either; it only raised the requested VRAM from 14.5 to 15.8 GB.In the #394 + #373 run, the title's 30 s watchdog (
+0x23CF683) fired 2 s after the device loss, so its exit code was 5 instead of 3. That's the "watchdog hides a device loss" case from #215, not the old intro stall.What I can't see
Without breadcrumbs I can't tell which work the gfx ring was running. Things that might matter:
pipeline has no paged descriptor layout: its root indexes the resource heap directly, from two of the callers in this issue's description:0x248cbc1: 11, 8, 0, 1 and 0 times, in the order of the five runs;0x4e33f98: 0, 6, 1, 16 and 2 times.Question
How did you build vkd3d-proton
cae8353ewith breadcrumbs? A meson option, a patch, or a build script? And how do you put it into GE-Proton11-14: replacing thed3d12.dll/d3d12core.dllin the Proton folder, or throughPROTON_*/WINEDLLOVERRIDES? With that I can run the same trace on this card and report the unfinished region.Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-28T13:20:09Z.
@1093i3511, thanks, that matches what we see on the RTX 5090 (620.70.10). There it ends as Xid 109 (context-switch timeout), also with no page fault, about 20–140 s after the story load, and in builds that have #372, #376, #394 and #386–#391.
Measured, with vkd3d-proton breadcrumbs (NV checkpoints) and a TuxBox trace of every mesh
ExecuteIndirect. The trace copies each draw's argument records on the GPU and marks the draw completed afterwards.ExecuteIndirectwith MaxCommandCount 1 and no count buffer.MS_VS_TransformDwithPS_DeferredTextured. It comes right after a chain of indirect compute dispatches and reads a small dedicated 32 KiB argument buffer. The other two were particle-effect mesh draws.DispatchMeshrecords the GPU read for the unfinished draws are small: (0,1,1), (1,1,1), (2,1,1), (29,1,1). Several have X = 0. None is over the 65,535 or 2^22 limits.Inferred, not tested: since both vendors time out on the graphics ring at the same point, the likelier cause is what TuxBox records or translates for this draw, rather than a driver quirk. One example would be a memory access inside the draw that never completes.
We're looking next at how the zero-count mesh indirects are executed, and at #390 and #396.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-28T13:35:26Z.
A correction to my comment above.
vkCmdDrawMeshTasksIndirectEXTanyway.)CS_Prop_BatchCull, and three other compute queues were waiting on labels a direct list never reached.ExecuteIndirect(MS_VS_TransformD/PS_DeferredTextured), after every earlier command had completed.Inferred, not tested: a lane of the batch-cull program may loop until its translator guard runs out. We're testing that next with an A/B run that makes that one program a no-op, and with the trace fixed.
Imported from brcly/TuxBox. Originally posted by 1093i3511 on 2026-11-28T18:24:29Z.
An update to my AMD data point above. On current
mainthe page faults are back on RDNA2, and now they end in a full GPU reset. Memory numbers for the same runs are on #292.Setup: RX 6600 (
1002:73ff, RDNA2, 8 GB), Mesa RADV 26.3.1, Linux 7.3.6, GE-Proton11-14, Microsoft DXC 1.9.2609.main2af42c9(contains #394 and #396, not #390), D3D12 provider sha256e9a5f358…,XboxBvhBuilder.dllf9d957b9…. Full prepare,TUXBOX_TRACE_GPU_FAULT=1, otherwise default settings.Two runs, the same ending
comp_1.1.1ring reset failed, MODE1 resetcomp_1.3.0ring reset failed, MODE1 resetRun 2's kernel log:
Run 1 faulted at
0x17561f000, then at0x0. These are the same client and status as with #320 alone (TCP,PERMISSION_FAULTS: 0x3). This time the compute ring reset fails, so the kernel resets the whole GPU and VRAM is lost. That took down my Wayland compositor both times. Before, the ring resets succeeded and the desktop stayed up.On this card the
pr-394head (928abca) had no faults, andpr-394+ #373 had none either. So something merged intomainsince then brings them back here. I haven't isolated what.What comes before the fault
In both runs, the 10–20 s before the fault have lines like these. There were 7 in run 1 and 8 in run 2:
There is also one line from vkd3d-proton per run:
In the first line of each pair, the address "now resolves to" itself (
0x179dac100), not to host storage. The faulting pages (0x175…,0x177…) lie just below these AS sources (0x179…–0x17a…). That's only proximity; I can't tie a fault to one of them.The GPU fault trace can't report here
GPU fault trace: marking every draw and dispatchappears, but no report follows. On this host:VK_ERROR_DEVICE_LOST.The watcher in
gpu_trace.rschecksGetDeviceRemovedReasononce per second, and its "no marker changed" report waits 8 s. So it never runs before the process is gone. If the report ran right when a submission or wait first returns device lost, or the marker ring were checked more often, it might get out in time. I haven't tried either.Not established
e380da1(lists whose structure source got new storage) and textures placed in system memory (ce8a7c8), but that's a guess.If useful, I can run
mainwithTUXBOX_VRAM_RESERVE_MIB=offto see whether the faults follow textures in system memory.Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-28T19:49:06Z.
@1093i3511, thanks: the "given new storage" lines you quoted pointed straight at it. The fix is #409.
Cause. A structure built in title memory gets its storage when its build is recorded, not submitted.
e380da1such a list was refused, so its queue just stopped. Sincee380da1it runs. Its copy or size query uses the storage it recorded, but a scene it builds over the structure, and later lists, read through the bad address.Your faulting pages (0x175…, 0x177…, 0x0) are title-range addresses, which fits. That last link is inferred: I haven't tied your fault to this exact path.
Repro without the game. Lanes
ray-tracing-guest-memorynow also builds a scene over the structure in the earlier list, and traces a ray through it.mainit hangs an RTX 5090 (Xid 109) and the self-test never completes.Fix (#409). The list that writes over a structure keeps the older storage alive, and withdraws the older address only when it's submitted. A list whose source got new storage after it was recorded keeps using the storage it recorded. The full check passes on both GPUs.
If you can, a run of #409 on your RX 6600 under the same conditions would confirm it.
Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-29T11:44:24Z.
Caught an Xid 109 with TUXBOX_TRACE_GPU_FAULT on an RTX 3080 Ti (620.73.04, GE-Proton11-14, main at
28717263plus #450), this time with TuxBox's XboxBvhBuilder.dll in place. About 4 minutes in, atGame Runningwith the intro prestreaming:The only unfinished command is a compacting acceleration-structure copy, and its native addresses equal the guest ones, so it took the branch in
raytracing.rs::recordwhere neither end resolved to a registered structure. Just before it, two GPU memory waits were held past 5 s for a write still to run (target 0x187e, value 0x187d), and the title's crash report lists an unsignaled cross-queue barrier. The kernel logged Xid 109 at the same time.For comparison, a run on the same build with the package's own XboxBvhBuilder.dll ran 1 h 58 min to the same scene with no Xid. I'll repeat with TUXBOX_TRACE_RAYTRACING=1 to see where that source structure came from.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-29T11:49:36Z.
That matches something merged since your build: #436 (in
mainfrom62373772), which your28717263+ #450 doesn't have. In title memory that never held a structure of ours, it no longer gives such a copy to the host: it's skipped, and the destination is withdrawn so a later scene finds nothing there. Before it, on an RTX 5090, I had runs where such copies (neither address registered) were given to the host and the device was lost later; I have no controlled comparison that ties them to Xid 109.I can't tell from the marker that yours is the same one, so a run on today's
mainwould show it. #461 (open) closes a related gap: a build that was refused keeps its storage, so a copy of it still reached the host.Your 1 h 58 min run with the package's own builder is a useful comparison. If you still see Xid 109 on
mainwithTUXBOX_TRACE_RAYTRACING=1, the line for the copy's source would say what the title thought was there.Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-29T11:53:23Z.
Follow-up with TUXBOX_TRACE_RAYTRACING=1. This run drew the opening scene and the first title card, then hit Xid 109 again. Unfinished: CS 2a84fca5 (w32) and
copy_as mode=1 guest_src=0x1760dcd00.History of that source in the log, in order:
AS storage 0x466140000..0x466150000 placed 0x1760dcd00AS storage 0x466140000..0x466150000 taken from 0x1760dcd00Copy placing unknown AS at #1760dcd00About twenty addresses follow the same placed, taken, then copied-into pattern within the same second. After the storage is withdrawn, a copy into that address resolves neither end and seems to take the
(source, destination, None)branch, so the GPU later compacts from title memory that isn't a structure. I can test a patch.Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-29T11:53:41Z.
Thanks, that fits. That run was on
28717263+ #450, so before #436. I'll rerun on today's main with TUXBOX_TRACE_RAYTRACING=1 and TUXBOX_TRACE_GPU_FAULT=1 and post whether Xid 109 still happens, and if it does, the copy source's history. For the record, this run on the older build drew the opening scene and the first title card before the hang.Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-29T12:26:31Z.
Ran today's main (
6e2c5da, with #436 and #455) on the RTX 3080 Ti with TUXBOX_TRACE_GPU_FAULT=1 and TUXBOX_TRACE_RAYTRACING=1. The world scene was on screen for several minutes at 12–20 s per frame, and Xid 109 came 942 s after launch instead of about 240 s. No acceleration structure copy was left unfinished this time, so #436/#455 look to have fixed the one I caught.This time the trace left 37 draws unfinished, all in list 0x7431f980 and all mesh-shader draws:
The memory ledger had the card at 7592 of a 7613 MiB budget at that point. The title's crash report again shows Game Running in the intro with an unsignaled cross-queue barrier.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-29T12:49:32Z.
That's a good result, and very useful that the copy is gone. The rest looks like a different thing.
What you have left is all mesh draws, and your card is the same vendor as mine. I've been chasing a wrong-result fault in translated mesh programs on NVIDIA (#458): with 128 lanes, the first 32 get a wrong register value, right on AMD and right on 32 to 127 threads. I can't say yours is it: none of your MS digests is among the recorded mesh requests I have by that name, so they may be named differently, and a hang isn't a wrong value.
A cheap way to check on your side: #470 (yours) can leave out draws by shader. Leaving out those PS/MS pairs one or two at a time would say which draw it needs.
On mine, the same build family (
maind2eb99edplus #462, #455, #463) ended the latest traced run (Xid 109) with a use-after-free: the GPU read a 128 KiB region that had been freed 6.9 s earlier. The pending list there was mesh draws too, allExecuteIndirect. I'm running it again with import tracing (TUXBOX_TRACE_IMPORTS, not upstream). Your card's memory ledger at the limit (7592 of 7613 MiB) may be a separate matter, as 1093i3511 reports on 8 GB.Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-29T13:01:14Z.
Already on it: this run is on #470 with TUXBOX_SKIP_SHADERS=b919add5, the mesh shader of the earliest unfinished draw from the last trace (PS 9aa10000 MS b919add5). The log confirms it took: "PS 9aa10000 MS b919add5: draws left out, b919add5 named in TUXBOX_SKIP_SHADERS".
It is now about 20 minutes in, past the 942 s where the previous run hit Xid 109, and still going: the intro has moved on through several camera angles, the HUD drew a contact card, and the opening credits are rolling. Frames are still 10–20 s each, the exposure takes a while to settle at that rate, and there is a fixed vertical seam just left of centre where the two halves of the picture are exposed differently.
I'll post the trace and timings when it ends. If it gets through without Xid 109 I'll also try the other pairs one at a time, as you suggest, to see whether b919add5 alone is enough.
Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-29T13:08:10Z.
Result with #470 and TUXBOX_SKIP_SHADERS=b919add5: the skip took (the log names the pipeline), and the run got further than ever on this card, through the opening credits into daytime scenes, but Xid 109 still came at 1409 s (previous run 942 s).
This time 12 draws were left unfinished, earliest #362994 PS 479dd951 MS 07906255, so b919add5 alone wasn't it. Four pairs were unfinished in both runs: c01a576e/5d1cc513, e31822fd/16b4f5f5, 0dd415ad/9e6ae248, 90d975f7/9aae03a2.
What both runs share is the card being full at the moment of the hang. The memory ledger climbs steadily through the run and was at 7428/7450 MiB when this one hung (99.7%); the previous one was at 7592/7613 MiB. That fits your use-after-free better than any single shader. Next I'll run the same build with TUXBOX_VRAM_RESERVE_MIB=4096 to keep headroom on the card and see if the hang moves or goes.
Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-29T13:33:03Z.
Two more runs on the RTX 3080 Ti, and both rule something out:
TUXBOX_VRAM_RESERVE_MIB=3072 kept the card at 6549/7919 MiB (82%), and Xid 109 still came at 741 s. So the card being full at the earlier hangs was a coincidence, not the cause.
Right after that Xid 109 the kernel logged Xid 31: "MMU Fault: ENGINE GRAPHICS GPC2 GPCCLIENT_T1_9 faulted @ 0x4_9b509000. Fault is of type FAULT_PTE ACCESS_TYPE_VIRT_READ", a GPU read of an unmapped page. That fits your use-after-free.
Also measured, with a local experiment that left render and depth targets out of publication: in-world frames stayed at 13–21 s each. The long publication windows were 4.5 s for 2.8 MiB and 5.4 s for 2.2 MiB, so they're waiting, not copying. On this card the frame time isn't publication volume.
For the record: the game's audio played during the intro on this run, ahead of the picture as you'd expect at these frame times.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-29T13:49:22Z.
Thank you, and that changes my reading for the better. Your runs have none of my experiment (#459, now closed, computed wrong values in some mesh programs on NVIDIA; it was in all the game runs I reported from the 5090 in the last hours), and you still get the unmapped-page read after Xid 109. So that fault is in
main, not mine alone, and it isn't only the card being full.What I know, from two traced 5090 runs that did carry it, so please take it as a lead: the page read was inside an import of title memory that had been released, 6.9 s before in one, and about 15 s after a clean release (all submitted batches finished) in the other, with the same low byte of the fault program counter both times. So I read it as something still naming a released import, such as a descriptor, rather than memory freed too early. I'm running the same trace again without the experiment, with a recorder for which descriptor slot names each released import, and I'll post what it shows. If it shows something, I can push that branch so you or @1093i3511 can run it on your cards.
Your publication numbers (4.5 s for 2.8 MiB) fit waiting, as you say. On #472, DrArroway sees 12–24 s per frame with #464's section-backed pages against 3.4 with private views on a 6900 XT, which is the same size as your 13–21 s.
Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-29T15:41:21Z.
Thanks. I'll run your recorder branch on the 3080 Ti as soon as you push it.
One more data point in the meantime: with every translated loop capped per stage (1,024 pixel, 4,096 other raster stages, compute unchanged at 65,536, a local build on top of #470), a run on this card went through the intro for 15–20 minutes and ended on Xid 13 at VS 281b4977 PS 96e8aaaa, the distant-lights draws in the setup guide, rather than Xid 109. One run only, so not a result yet, but it's the first time this card has reached the same fault as the AMD world run instead of the hang.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-29T22:04:49Z.
@ReverendOzmund sorry for the wait: here is the recorder I promised, branch
diag/lost-gpu-recorder, on currentmain(97f21fad). It only records and waits; nothing in it is on unless you set it. It doesn't have the descriptor-slot recorder: that experiment didn't hold up and I withdrew it.TUXBOX_HOLD_LOST=40keeps the game alive for up to 40 s after the GPU is lost, so that vkd3d-proton can print its report before the game's crash handler ends the process. The game looks frozen; let it be.TUXBOX_TRACE_IMPORTS=1keeps a list of title-memory imports and prints it at the loss. It needsTUXBOX_LOG, and signals a fence per batch, so it costs some speed.VKD3D_CONFIG=faultprints the address and instruction the driver blames.breadcrumbsnames the unfinished draws, but stock GE-Proton11-14 is built without that report: you will getfaultonly, unless you use a trace build of vkd3d-proton.After a loss, please send the output of
python tools/classify_loss.py game.log, and these lines (not the whole log: it holds paths and user names):If classify_loss.py names an import near the fault, add the
import ring releasedandimport ring livelines it matches. They hold memory addresses, not contents. Please look through what you paste.Limits: on our RTX 5090 (620.70.10) the hold has worked in several runs, but the driver doesn't always report an address. It gave none in our last loss (an instruction address only), and the kernel log was then the only other source. No report means it wasn't printed, not that nothing faulted. If an earlier loss ended in Xid 109 without a fault, this may show nothing. The branch has unit tests and
check --no-gpu; I haven't run this exact branch in the game, though its parts come from builds we have run.Your Xid 13 at
VS 281b4977 PS 96e8aaaais interesting next to our own late losses in mesh draws (Xid 13, no address); if this names an import or an address, I'd like to compare.Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-30T02:18:50Z.
Thanks Nick. I'm folding the recorder into my next run: main + #557 + #501 private views, with TUXBOX_HOLD_LOST=40 and VKD3D_CONFIG=fault. I'm leaving TUXBOX_TRACE_IMPORTS off this time because the run is also measuring #501's frame times on NVIDIA. If it loses the device without an address, the next run turns the import trace on. I'll post classify_loss.py's output and the Xid lines.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-30T03:58:06Z.
@ReverendOzmund, a result from our RTX 5090 (
10de:2b85, 620.70.10, GE-Proton11-14) that may help with yours. One run, 19 minutes into the world (the GPU was lost at 1790 s, Xid 13, MMU fault in a shader, about the same class as in your report but not the same Xid). The first with a fault address:ReadInvalid 0xdcf6068000. vkd3d-proton's binding log says the address was in an image's range of 0xb0000 bytes (BIND, UNBIND, BIND, then the last UNBIND 846 s before the fault), "very likely use-after-free". 34 mesh ExecuteIndirects were unfinished.That doesn't name the texture or the descriptor. The likely kind is a reserved placed texture (guess). I've filed two log-only diagnostics as drafts, #567 (which ended images descriptors still name, when the device is lost) and #568 (what the indirect mesh records hold), both off by default and neither run on a GPU yet. If your next run has room for
TUXBOX_CHECK_STALE_IMAGES=1orTUXBOX_TRACE_MESH_RECORDS=cpu, either would help; keepTUXBOX_HOLD_LOSTset. I'm running both now.Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-30T04:55:31Z.
An update to my comments here, with two corrections.
In a second traced loss on the RTX 5090 (84b, 11 minutes into the world, Xid 13) with both #567 and #568 on:
0x1030b5000; vkd3d says it's in no allocation. Correction: I said the address was in the title's own address space. It isn't: it's a GPU address. No import or placement we logged lies between 4 GiB and about 0x123e70000, and it's in that gap; 27 of the 65 invalid-access pages in our older logs are in the same band, three of them the same page in different runs.de01af6fdee17682/566c096c9479b982), also in flight in 83a. None of the programs we disassembled dereferences a 64-bit pointer. The pair does index the resource heap with values from title data (27 bits, unbounded in the map lookup).Best remaining family, inferred: a resource-heap descriptor read through a wrong or unmapped slot. About 1.04 million index-map entries without a slot hold records; today such an index reads whatever visible slot 0 holds. I have a small fix for that (a null view instead) and will run the game with it next; a clean run or two wouldn't prove anything, so I'll repeat it.
Third traced loss (86a, with the null view of #572 active, 9 minutes into the world): the GPU was still lost. So a missing index-map slot's view isn't it. The fault page was
0xdb21d75000, inside a range vkd3d had bound to an image and unbound 288 s before. Both freed-image faults (83a and 86a) are in the last 64 KiB tile of the image (offset 0xa8000 of 0xb0000; 0x155000 of 0x160000), which is usually the packed mips. Again no followed descriptor named an ended image (#567), so if that is a stale texture, our diagnostic misses a path. 67 of the unfinished draws usedMS b91b86fc, one of @Jerkin42's programs. Looking at the paths now.Imported from brcly/TuxBox. Originally posted by ReverendOzmund on 2026-11-30T07:10:57Z.
Run with #567 (TUXBOX_CHECK_STALE_IMAGES=1), plus #572, #566, #563, #564 and #501 private views, RTX 3080 Ti, 620.73.04. Lost at 3214 s:
So no stale descriptor behind this one.
On your comment to Jerkin42: across eight losses here, MS 4db9a403 / PS 9b9409d0 never appears among the unfinished draws. My mesh losses were MS af7d9fb0, 5d1cc513, 16b4f5f5, fdd6bb48, b5f8d653, e8f8c6c0, 5082fbe3, 93e1ef9a and 89c17cf9. My one earlier Xid 31 was at 0x4_9b509000, not in the 4 GiB gap. Happy to test #390 once it's rebased onto main.
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-30T07:19:18Z.
@ReverendOzmund thank you, that's a clean negative on a second card, and the list of draws is worth as much as the stale-image result:
MS 4db9a403/PS 9b9409d0not in any of your eight losses (it's in ours and @Jerkin42's AMD one), and yours near the memory limit (7,474 of 7,620 MiB, 1,090 failed allocations). So there look to be several different faults under the same Xid, and I won't treat that pair as common to all of NVIDIA. Our own default-mode runs have also been lost well below the card's limit (a 32 GB card), so memory isn't behind ours.#390 is rebased onto main's reformat:
d3d12/mesh-index-map-bitmap, f172e332 one5d2e913(MathiewMay's commit plus two tests of ours). @Jerkin42's AMD run with it got past the faults it had in the PROLOGUE draws; our NVIDIA builds always had it. If you can run it, the interesting question is whether your distant-lights fault (VS 281b4977/PS 96e8aaaa) changes; I don't expect it to.Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-30T09:35:47Z.
A traced loss from tonight, RTX 5090 (
10de:2b85, 620.70.10, GE-Proton11-14), about 3.5 minutes into the world, Xid 13. One run, withVK_NV_raw_access_chainsdisabled, #572's null view on, #390 in, and #567/#568 on (f482572aplus our PRs, not current main):ReadInvalid 0x108ddf000, in the empty gap just above 4 GiB that two earlier traced losses here were in. vkd3d-proton's binding log: "Found no candidate VA entries. Page fault was likely caused by accessing never used memory or out of bounds access."MS 4db9a403is among the unfinished draws again (9 of them; 40 areMS 84798173). That mesh shader is in all three gap losses we've traced. It isn't in @ReverendOzmund's.@Jerkin42's unbounded heap index (#472) is the lead we'll test next: the padding diagnostic against a control run without it on the same build.
Imported from brcly/TuxBox. Originally posted by TheLore64 on 2026-11-30T15:03:27Z.
Confirming that @ReverendOzmund's VRAM-pressure distant-lights fault (
VS 281b4977/PS 96e8aaaa) also reproduces identically on AMD RDNA 4 (Radeon RX 9070, Mesa 26.0.8 RADV GFX1201, GE-Proton11-14) onmain(f7afdd16):adapter=1002:7550 wave=32-64 section-import=substituted descriptor-bytes=32/16 mesh=yes rays=yestoken=6049,1069.5s), with0pending shaders (61empty stand-ins).13,734 / 14,040 MiB(vkd3d_allocate_device_memory: Memory allocation failed, falling back to system memory,placed texture #8192 put in system memory), RADV lost the context on aTCPGPUVM read fault:radv: GPUVM fault detected at address 0x8002a3a44000GCVM_L2_PROTECTION_FAULT_STATUS: 0x40113b(CLIENT_ID: TCP 0x8,WALKER_ERROR: 5,PERMISSION_FAULTS: 3,MAPPING_ERROR: 1)TUXBOX_TRACE_GPU_FAULT=1result:GPU fault trace: fence signaled UINT64_MAX (device lost); 1 commands started and not finished, of 188137 recordedGPU fault trace: #185931 list 0x765c1b80 draw VS 281b4977 PS 96e8aaaaSo
VS 281b4977/PS 96e8aaaaappears to be cross-vendor whenever device-local VRAM fills up andvkd3d-protonspills textures into system memory.Imported from brcly/TuxBox. Originally posted by DrArroway on 2026-12-01T00:27:49Z.
Here is a
TUXBOX_TRACE_GPU_FAULT=1capture from the intermittentTCPPERMISSION_FAULTS: 3RADV GPUVM fault on AMD Radeon RX 6900 XT (1002:73bf):1002:73bf), Mesa26.3.1-arch3.5(RADV NAVI21),GE-Proton11-14,TUXBOX_XMEM_PRIVATE_VIEWS=1,TUXBOX_TRACE_GPU_FAULT=1adapter=1002:73bf wave=32-64 section-import=substituted descriptor-bytes=64/16 mesh=yes rays=yesd3d12_xs.dllandxshaderonmain40a69c3f(post-#389/#594),xmem.dllwith#600plus an in-progressxmemheld-alias fix (the sameTCPPERMISSION_FAULTS: 30x800...GPUVM fault family has also reproduced intermittently on stockmain40a69c3f)324.5s,token=8267,0device-local allocation failures;53type-5/10 fallback warnings earlier in the run):memory ledger: card 14616/15709 MiB, adapter system memory 5140/31597 MiB, upload staging 0 MiB, title pages 7131 MiB, process commit 17224 MiBtexture ledger: unbacked 442 (112 MiB), card 21971 (6432 MiB) (title ranges 6514 MiB, 5334 MiB distinct), system 6389 (1442 MiB), committed 3209 (3 MiB)Unlike the
VS 281b4977/PS 96e8aaaadistant-lights VRAM-exhaustion fault reported above, all four unfinished commands here aredraw VS 72817cd3 PS 9bcac3efwith ~1.1 GiB VRAM headroom and zero device-local allocation failures.Imported from brcly/TuxBox. Originally posted by DrArroway on 2026-12-01T00:47:46Z.
Follow-up
TUXBOX_TRACE_GPU_FAULT=1capture on the same setup (AMD Radeon RX 6900 XT (1002:73bf), Mesa26.3.1-arch3.5RADV NAVI21,GE-Proton11-14,TUXBOX_XMEM_PRIVATE_VIEWS=1), hitting the exact sameTCPPERMISSION_FAULTS: 3(RW: 0)0x800...GPUVM fault signature — this time on a compute dispatch (CS 482ad7dc) instead ofVS 72817cd3 / PS 9bcac3ef:427.8s,token=8298,0device-local allocation failures;102type-5/10 fallback warnings earlier in the run):memory ledger: card 14373/15482 MiB, adapter system memory 5587/31593 MiB, upload staging 0 MiB, title pages 7131 MiB, process commit 16553 MiBtexture ledger: unbacked 319 (44 MiB), card 16187 (5135 MiB) (title ranges 4748 MiB, 4273 MiB distinct), system 6615 (1459 MiB), committed 2073 (1 MiB)Catching a completely different shader (
CS 482ad7dchere vsVS 72817cd3 / PS 9bcac3efpreviously) under the sameTCPPERMISSION_FAULTS: 3(RW: 0) signature at ~14.4–14.6 / 15.5–15.7 GiB card usage and zero device-local allocation failures points away from a single-shader bug and toward a shared resource/descriptor/page-table-lifetime cause.Imported from brcly/TuxBox. Originally posted by brcly on 2026-12-01T03:24:49Z.
A possible link, for those chasing the Xid 109 and late GPU losses: at least at the story intro, tonight's runs on a 16 GB card stall when video memory fills and placed textures spill to system memory. The Xid 109 we saw came during that spill. Details and timeline are in #533.
Imported from brcly/TuxBox. Originally posted by brcly on 2026-12-01T15:14:26Z.
Update for anyone testing this: main changed today in ways that affect long runs. Read residency, lazy publication and once-per-frame checks are now defaults, descriptor table eviction no longer holds the arena lock for most of a frame, and index map lookups are bounded. The summary is on #533. Please say whether a result is before or after
e40d8052. @DrArroway your two RX 6900 XT captures were on40a69c3fwith private views; a repeat on current main would show whether thePERMISSION_FAULTS: 3reads still come.Imported from brcly/TuxBox. Originally posted by DrArroway on 2026-12-01T18:26:29Z.
@brcly Tested current
main(post-e40d8052) on AMD Radeon RX 6900 XT (1002:73bf) (Mesa26.3.1-arch3.5RADV NAVI21,GE-Proton11-14):main93324a2b(soTUXBOX_READ_RESIDENCY=1,TUXBOX_CHECK_ONCE_PER_FRAME=1, and56627188index clamp active) + PR#630(e242a160, required to get past the#519slot 133768x768x6 R16_TYPELESSE_NOTIMPLassert at startup) +TUXBOX_XMEM_PRIVATE_VIEWS=1+TUXBOX_TRACE_GPU_FAULT=1+TUXBOX_LAZY_PUBLICATION=0(required on RADV here because default lazy publication currently triggers a-1(-EPERM) AMDGPU CS rejection before the intro, filed in#634).Result
The
TCP (0x8)PERMISSION_FAULTS: 3(RW: 0)0x800...GPUVM read fault still reproduces in the world at413.9s(token=8396,0xmemerrors,indices past the heaps 0) — and notably this time with zero VRAM spill:memory ledger: card 9463/15532 MiB, adapter system memory 3543/31603 MiB, upload staging 0 MiB, title pages 7131 MiB, process commit 15654 MiBtexture ledger: unbacked 28392 (7909 MiB), card 1903 (2788 MiB) (title ranges 2841 MiB, 2675 MiB distinct), system 0 (0 MiB), committed 3591 (3 MiB)read residency 5.1s: kept 144753 views (166729.5 MiB), left out 3086553 (2855709.5 MiB), textures read 2406, indices past the heaps 0RADV +
TUXBOX_TRACE_GPU_FAULT=1output:(Kernel
journalctl -kalso showed[gfxhub]PERMISSION_FAULTS: 0x3on0x800516964000and0x800516965000alongside0x800521292000, followed byring gfx_0.0.0 timeoutand aMODE1GPU reset.)(Compiled pixel shader hash:
89f6b548aa89de1d9dcd86516820e216e6a2cc4a66dede702ba18f51472c955a.)So read residency cleanly kept VRAM usage around ~9.5 / 15.5 GiB with
0 MiBsystem textures, ruling out VRAM spill here, and the trace caught a third distinct shader pair (MS 5f6ec27e / PS 89f6b548, alongside the earlierVS 72817cd3 / PS 9bcac3efandCS 482ad7dccaptures), which fits@Kayotic1337and@1093i3511's use-after-destroy findings in#603. Happy to follow up with aRADV_DEBUG=hangcapture on this setup if that helps pin down the faulting binding.