[Windows / Vulkan] Reproducible 0xC0000005 at game_scarlett_master.exe+0x23cf683 ~40 s after two E_DSTORAGE_DECOMPRESSION_ERROR reads #2019
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 ubiquitarianism/leonida. Originally posted by azmuricy466-pixel on 2026-11-25T18:15:02Z.
Summary
gta6rt --first-run-uiloads the title, shows the splash and runs the first-run UI, then the titlewrites to
0x0atgame_scarlett_master.exe+0x23cf683(0xC0000005, access=write). It reproduces onevery run, at 145–204 s, always after exactly two DirectStorage decompression failures with
E_DSTORAGE_DECOMPRESSION_ERROR(0x89240030). No world frame is ever presented.Environment
main@71a769d7, built withscripts/build_runtime.ps1,-DLEONIDA_SDL3=ONwith SDL3 3.4.20shared (
SDL_SHARED ON,SDL3::SDL3),-DLEONIDA_REQUIRE_VULKAN=ON, RelWithDebInfomake_game.py --stages check,shaders,runtime→ 26,503 shaders translated,check all files present and hashes match
TdrDelay/TdrDdiDelayraised to 60 s (a 8.9 s pipeline build no longer resets the device;device was losthas not recurred since)Command
Trace (three runs, identical)
Other runs: failures at t=135.9/136.1, crash at t=203.85; failures at t=113.5/113.6, crash at t=157.85.
The two failing reads are always the same file ranges and the same sizes.
unimplemented_callevents: none.
int3: none.What I tried
LEONIDA_DSTORAGE_FITTED=0 LEONIDA_DSTORAGE_FAST_BCPACK=0→ worse: 120 decompressionfailures and an earlier, different xmem fault. Reverted.
Guess
The two failed decompressions leave a destination buffer in a state the title does not test; the
title later writes through a pointer derived from it. If those two reads can be made to succeed (or
return a well-formed block), the crash may move on. Happy to run
LEONIDA_DSTORAGE_TRACE=1and sendthe request list for those two ranges, or any diagnostic build you want.
Notes
a1ed7bcb, no SDL3) the run died earlier atgame_scarlett_master.exe+0x104075(read 0xffffffffffffffff); the TLS-slot work fixed that.Player, no crashes up to the pointabove.
Imported from ubiquitarianism/leonida. Originally posted by azmuricy466-pixel on 2026-11-25T18:25:33Z.
Update with
LEONIDA_DSTORAGE_TRACE=1(same build, same command, plusLEONIDA_SKIP_INT3=1):Both failing reads are in the same file, both BC7 page destinations:
data/ttdb/props/octa_imposters.ttpfis 35,286,784 bytes and matches the size and SHA-256 ingame/xbox-1.0.2.1.json, so the archive is not the problem.LEONIDA_SKIP_INT3=1changes nothing(no
int3is logged); the crash is stillgame_scarlett_master.exe+0x23cf683write to0x0, thistime at t=199.87 s, ~48 s after the two failures.
Also note: with
LEONIDA_DSTORAGE_FITTED=0 LEONIDA_DSTORAGE_FAST_BCPACK=0the same file produces120 decompression failures instead of 2 and the run dies earlier with an xmem read fault, so the
fitted-predictor path is doing the right thing for the other blocks here.
Imported from ubiquitarianism/leonida. Originally posted by Snooozs on 2026-11-25T19:57:43Z.
Two separate things, as far as I can tell. Counts, offsets and addresses only.
The crash at
+0x23cf683is the title's hang watchdog, not the decompression. I have a run with the same stop and no DirectStorage failure at all (RTX 5060 Ti, NVIDIA 621.01, Windows 10): write to 0x0 at t=173.8 s, stack+0x23cf683,+0x2215c35,+0x2215eca.+0x2215c35is the watchdog's own trap:runtime/src/main.cpp:36-43describes it (function at RVA 0x2215a60, 30 one-second ticks without a kick from the main loop, then a crash callback and the write to address 0). DadaCap recorded the same stop and the same two callers in the body of #1537. A main loop stalled for 30 s by pipeline builds or by a wait is enough.To check it: compare the
stackof yourexceptionevent (seq 205) with those three addresses, and run once withLEONIDA_TITLE_WATCHDOG=0(runtime/README.md, it only acts when the trap bytes are where this build has them). If the stop disappears or the stack matches, it is the watchdog, and the question is what stalls the main loop for 30 s in your run (your log's lastsubmit phaseslines show where the submit thread was). I have not tested whether it keeps your run going.The two
0x89240030reads are known: #1715 lists exactly your two BC7 requests ofdata/ttdb/props/octa_imposters.ttpf, at 455285504 (768 blocks) and 76014336 (1,536 blocks), each with one endpoint entry the reconstructed profile does not know, and decodes both with a lost-block limit of 1/32 (LEONIDA_DSTORAGE_LOST_DIVISOR). Its description says it was checked against the package, not in a boot, so whether it changes your run is open.LEONIDA_DSTORAGE_FITTED=0making it worse is expected (docs/directstorage.md: it needs confirmed entries).AI-assisted (Claude Code, Claude Opus 5.5).
Imported from ubiquitarianism/leonida. Originally posted by azmuricy466-pixel on 2026-11-26T03:54:18Z.
Thanks — that reframed it completely. Two data points now.
0xC0000005, write to 0x0, t=199.87 s) hasso we agree it is the title's own hang watchdog, not the decompression.
2. With
LEONIDA_TITLE_WATCHDOG=0the game gets past the old dead point, and then the machine blue-screens.RTX 5090, 32 GB, Windows 11,
TdrDelay=60for the test (reverted to default afterwards).then at ~t=3 min, before any world frame, the box bugchecked:
So disabling the watchdog does not get us into the world — it converts "title kills itself in 30 s" into "the main loop never comes back and takes a critical system process with it". Not asking you to support that config; it just tells us the stall is real and long, and it happens right around the compute pipeline builds:
Question: is the pipeline build on the main thread by design right now (so a slow build is indistinguishable from a hang), and is kicking the watchdog from inside the build loop — or moving these builds off the tick — something you would accept a PR for? If you already have a branch or a preference for how it should look, point me at it and we can try a patch on our side to confirm the diagnosis before anything else.
Imported from ubiquitarianism/leonida. Originally posted by nicoco23 on 2026-11-26T16:12:42Z.
Second Windows/NVIDIA data point: i7-12700KF (Intel, no SSE4a/CLZERO/MONITORX), RTX 5070, 32 GB, Windows 11 26200, main
73516a2+ #2195 (the TLS atexit fix — without it the title's CRT aborts at startup).Imported from ubiquitarianism/leonida. Originally posted by azmuricy466-pixel on 2026-11-26T17:02:10Z.
Data point, no action request — this fills two of the TBDs in
docs/running.md→ Windows, NVIDIA.Setup.
ubiquitarianism/leonidamain56bdd7e,scripts/build_runtime.ps1(SDL3 static, RelWithDebInfo), RTX 5090 32 GB, driver 616.92, Windows 11.TdrDelay/TdrDdiDelaywere deleted from the registry after the bugcheck, but the running boot still came up with 60 s (the keys are read when the driver initialises), so the two runs below ran with 60 s; a re-test with the stock 2 s is still pending. shaders+runtime built bymake_game.py --stages check,shaders,runtime; package check passes (108 files).The pipeline stall is gone without the KICK values. With
the title watchdog never fires and
compile-gatenever reports a wait. Previous runs with the default pipeline settings (and with a warmpipeline_cache.session.bin) stalled 32.1 s on one compute create —compute library/lib_cs_01261, 692564 B SPIR-V— and the watchdog exited the process at t≈48.9 s. SoPipeline pre-compile:can be written as "not needed for the first-run UI:LEONIDA_FAST_PIPELINES=computekeeps the main loop alive".What is behind the watchdog. Two consecutive runs, identical command line, both died on a title-side AV at different sites — this looks like the next stop, not the watchdog:
shadows342 ms of 696 ms) and the frame rate settled at 1.2–1.4 frames/s. At t=61.1 s:0xc0000005write atgame_scarlett_master.exe+0x7456da, address in aMEM_COMMIT/PAGE_NOACCESSrun withallocation_base=0x0.dstorage_failurecount this run: 0.0xc0000005read at+0x507b2f4on address0x8, then+0x18bae6freading0xffffffffffffffff. The runtime's own line right before it:xmem: title read fault at t+0x507b2f4 on 0x8 state 0x10000 protect 0x1 type 0x0 allocation 0x0, outside stream CPU window, unmaps 90531, no recent ma….Both are reads/writes into pages the title believes it owns (manually mapped,
allocation_base=0x0), so I read them as title-memory-map state rather than as a new class. I searched issues and PRs for0x7456da,0x507b2f4and"title read fault": no report names these offsets. The neighbouring work I found is #2163 (slot-133 shadow keeps the GPU's writes), #1897 (a page kept read-only by another tracker is copied once) and the closed #2240 / #1972 — so I am not filing a separate issue and will re-test once #2163 and #1897 land. If those two sites survive that re-test I will open a report with the traces.No payload, shader, texture or name list is included here; only RVAs, counters and frame rates.
Imported from ubiquitarianism/leonida. Originally posted by LGlong1 on 2026-11-28T06:24:25Z.
Another reproduction of
0xc0000005atgame_scarlett_master.exe+0x23cf683, on Windows 10 + AMD RDNA2, with a host-side fault just before it and no DirectStorage errors in the run.Setup. Windows 10 22H2 (10.0.19045), AMD Radeon RX 6750 GRE 12 GB (RDNA2), driver 32.0.21045.16010; commit
d442851,gta6rtbuilt from source with VS2022 + Windows SDK 10.0.26100;LEONIDA_D3D12=vulkan; the build needed the one disassembly fix from #2539 to get 26,503/26,503 shaders; assets stage 138/138.Reached. The title key art, the first-run landing prompt, and the first-run pages up to ROCKSTAR GAMES LEGAL TERMS & POLICIES (both check boxes and Confirm on screen). One run got the Privacy Policy box ticked; the crash came on the way to the loading screen.
The fault. Two runs, both ended with the same game-side exception:
The second run's startup trace holds two exceptions: first a host-side one in our runtime, then the game-side one above:
So this looks like the runtime's own read going wrong first, and the title faulting afterwards — possibly a different route into
+0x23cf683than the one in the issue's first report.What was happening at the time. The crashes came while compute pipeline libraries were being built: in one run 7 pipeline builds were still in flight and
lib_cs_01500alone took 21.1 s to build (683,908 B SPIR-V); the other run hadlib_cs_01966at 8.6 s and 7 builds still running at exit. Private memory was 26.9 GB (32 GB machine) in the first run, 20.7 GB in the second.Not seen. No
E_DSTORAGE_DECOMPRESSION_ERRORin either run (the DirectStorage shim reported no failures). Input was a real Xbox pad through SDL3 in one run andLEONIDA_INPUT_SCRIPTin the other; both reached the same page and faulted.Trace files and logs stay on this machine; no game files are attached.
Imported from ubiquitarianism/leonida. Originally posted by LGlong1 on 2026-11-28T07:11:36Z.
Follow-up from the Windows 10 / RX 6750 GRE (RDNA2) machine: the hang watchdog's two RVAs, measured here, and one Windows-AMD number that matters for it.
The crash site is the watchdog's callback, not its own trap. The dialog Windows shows is
0x00000001423CF683 ... written, i.e.game+0x23cf683. Disassemblinggame_scarlett_master.exeat that RVA:A write to address 0 with a non-zero immediate. The watchdog thread itself (RVA
0x2215a60, the function Snooozs named) has its own fallback write at RVA0x2215c35:That one matches the runtime's
kWatchdogTrapbyte pattern;0x23cf683does not. Before those lines the thread reads its "main loop alive" flags at0x471b6340(bit 0),0x471b6331,0x471b6330, and the last-kick timestamp at0x471b6338; a counter of0x1e(30) one-second ticks runs down, then it calls the callback pointer at0x471b6348(the write above) and then does its ownmovl $0,0x0.What I tried. With
LEONIDA_TITLE_WATCHDOG=0 LEONIDA_TITLE_WATCHDOG_KICK=2215c35,471b6331on commitd442851, the loader printed no "keeping the title's hang watchdog kicked" line and the run still ended at+0x23cf683. I did not try0x471b6330as the kick byte. Questions for whoever measured these: is the kick byte0x471b6331,0x471b6330, or something else this disassembly does not show; and should the trap check also accept the callback site (0x23cf683, pattern with the0x4d8bd421immediate) so a run whose only write-to-0 site reached is the callback can still be defused?Why it matters here: the 30 s is shorter than this driver's pipeline creates. On this machine the main thread stalls in compute creates:
so the watchdog fires on any run that meets one of them. On RADV the same programs are seconds (docs/linux_proton.md, step 2), which is why the world frame was reached there and not here.
One more Windows data point: the runtime built from
6dfca64(SDL3,scripts/build_runtime.ps1) crashes at startup on this machine before the title's first draw —0xc0000005read0x0athost:gta6rt.exe+0xbb13a, right after the title's TLS callbacks. Thed442851binary starts and reaches the first-run pages. The assets here were built from thed442851-eramake_game.py; I have not re-run the assets stage (2.5 h) to test whether that is the cause.Logs and traces stay on this machine; no game files attached.
Imported from ubiquitarianism/leonida. Originally posted by azmuricy466-pixel on 2026-11-28T17:46:50Z.
RTX 5090 / 616.92 / Win11, package 1.0.2.1 (108 files, hashes match), main
690dea5+ #1715.Eleven boots, first-run UI at 25-26 fps, all die at the same watchdog stop (0xc0000005 write 0x0 at game_scarlett_master.exe+0x23cf683) between t=120 and t=200 s.
Knobs that did NOT move it: FAST_PIPELINES+WARMUP (gate 2006 -> 447 ms), COMPILE_GATE=adaptive (submit-lock 12077 -> 2000 ms), HOST_IMAGE_COPY, ARENA_MB (capped 4080 MiB by ReBAR), TITLE_WINDOWS_MB 64/512/1024/2048 (127/199/121/129 s; every budget consumed to the last MiB), #1715 (ds errors 2 -> 0, stop unchanged).
What grows instead: 2943 title windows / 6552 copies / 2.4 GB, and "console descriptor heap (copy): 129.4 KiB each in 17.405 ms (fixing copied slots 15.105)" - the fix-up cost tracks the window count, so submissions reach hundreds of ms and the title misses its 30 s kick.
Two questions: (1) should a title window be released when the ring comes round again? (2) is "fixing copied slots" meant to be O(windows), or is #2566 the intended fix?
Imported from ubiquitarianism/leonida. Originally posted by LGlong1 on 2026-11-29T11:55:24Z.
Windows 10 + RX 6750 GRE 12 GB: 0xC0000005 ~70-105 s after the world starts, while 2-6 s compute pipeline builds are running (main
7b907de)Environment: Ryzen 5 5600X, 32 GB DDR4, RX 6750 GRE 12 GB (RDNA2), Windows 10 22H2, Adrenalin 32.0.21045.16010, game build v1.0.2.1. Runtime built from
mainat7b907de(runtime\build\gta6rt.exe, 15.14 MB, SDL3, xma/opus decoders built).Run:
gta6rt.exe --run <...>\game_scarlett_master.exe --game-dir <...>withLEONIDA_D3D12=vulkan. No ray tracing, default Series X.What happens: the title runs at 17-22 fps during load/menus. Once the world starts, the runtime builds compute pipelines of ~13-25 MB SPIR-V in 2-6 s each (
d3d12: compute pipeline library/lib_cs_XXXX (867520 B SPIR-V, warmup) build starts ...). At t ≈ 70-105 s the process ends with:No
E_DSTORAGE_DECOMPRESSION_ERRORlines in these runs (unlike #2019's original report).Watchdog:
LEONIDA_TITLE_WATCHDOG=0+LEONIDA_TITLE_WATCHDOG_KICK="2215c35,71b6338"is accepted now ("keeping the title's hang watchdog kicked"), but the crash is unchanged (~70-105 s), so either this is not the hang watchdog trap or kicking that byte is not what its check reads. Local disassembly of the title for this build (v1.0.2.1) shows the code around the trap at RVA0x2215C35(C7 04 25 00 00 00 00 00 00 00 00, byte-verified in the image) reads:0x71B6330/0x71B6331: flag bytes (mov cl, [rip+...]; test cl,1)0x71B6338: qword written a timestamp (mov [rip+...], rax)0x71B6334: dword tested (mov eax, [rip+...]; test eax,eax; je <skip crash>)0x71B6348: callback pointer called before the trapOur earlier kick RVA (
0x471B6331, from a different session) was outside the image; the corrected one (0x71B6338) is accepted but does not stop the crash. If the intended escape is "write 0 to the watchdog counter", the KICK thread currently writes 1, so it cannot satisfy it.Pipeline precompile also fails here:
gta6rt --precompile-pipelines --all --threads 8compiled 0 of 12 attempted 6-25 MB SPIR-V pipelines; each failed withVkResult -1after ~30 min of build, no cache files written (~107,000 s estimated remaining). The same pipelines do compile in-game in 2-6 s.Ask: (a) is there a documented way to get the faulting RIP/stack for the 0xC0000005 (we passed
LEONIDA_STACKS=1, no stack came out)? (b) is writing 0 to a watchdog counter supported byLEONIDA_TITLE_WATCHDOG_KICK, or should the RVA be a different byte? (c) anything else worth trying on a 12 GB RDNA2 + Win10 setup to get past the world-load pipeline storm.Imported from ubiquitarianism/leonida. Originally posted by LGlong1 on 2026-11-30T00:15:04Z.
Follow-up after updating to
452d1d1(+344 commits): the crash is unchanged; skipping the pipelines being built does not move itSame machine as my earlier report: Ryzen 5 5600X, 32 GB, RX 6750 GRE 12 GB (RDNA2), Windows 10 22H2, Adrenalin 32.0.21045.16010, game 1.0.2.1. Runtime rebuilt from
main452d1d1(15.23 MB), run asgta6rt.exe --run <game exe> --game-dir <package>withLEONIDA_D3D12=vulkan, no ray tracing, default Series X.What the update did help. With the pipeline journal populated (2,816 files,
pipeline_cache.d) the menus/loading now run at 50-52 frames/s, up from ~20 before; world load is 8-9 frames/s. So the journal seeding from #2392 clearly works on this card.What did not change. The world still ends with
0xC0000005:Crash times across runs on this build: 156 s, 209 s, 212 s (before the update: 45-105 s), always during or right after 1-6 s compute pipeline builds of 1-2.5 MB SPIR-V modules.
The skip experiment. I added the five programs being built at the crash to
LEONIDA_SKIP_COMPUTE(library/lib_cs_01055,01048,01056,00939,02384, run without--skip-listedso they stay out) and ran again: the game crashed anyway (t≈156 s, 0.00 frames/s just before the exception), on different work. So the crash is not tied to one shader or one pipeline size; it behaves like a runtime/driver fault that the next large compile or gate wait happens to trigger. This matches Snooozs's and azmuricy466-pixel's reports in this issue (the same watchdog stop on NVIDIA, and a BSOD/TDR when the watchdog is disabled), which suggests the watchdog is the visible symptom of a deeper fault, not the fault itself.Minor: after the crash the process sometimes cannot be terminated (
Access is deniedfromtaskkill /F); it stays until reboot. No device-lost line is logged in that state.Knobs that made no difference here:
LEONIDA_COMPILE_GATE=adaptive(auto was already adaptive),VICTORY_PIPELINE_WAIT_MS80 vs 500,LEONIDA_ASYNC_SUBMIT+lane core, mimalloc, a hard working-set ceiling at 22 GB, and the skip list above.Still available for any experiment you want run on Windows 10 + RDNA2; the journal from #2392 is built and warm, so a run costs about 4 minutes.
Imported from ubiquitarianism/leonida. Originally posted by aslan2142 on 2026-12-01T17:06:29Z.
Closing this issue because the legacy C++ Vulkan runtime (and legacy Python shader compiler) is now considered deprecated in favor of the new Rust Vulkan runtime (in progress) and the Rust DX12 runtime (
d3d12/) available now. Thank you for the report/contribution! If you believe this issue was closed by mistake (for example, if it still applies to active tools,d3d12/, or general docs), please feel free to reopen it.