Test report: RTX 4060 Laptop (8 GB), the world hangs the GPU, and VRAM is full #1508

Open
opened 2026-11-26 04:34:29 +00:00 by github-bot · 4 comments
Owner

@⁠Bladureau on GitHub · 2026-11-24 18:36 UTC · original

Setup

Commit ffe310e (and #1507 for the indirect state fix)
GPU NVIDIA GeForce RTX 4060 Laptop, 8 GB, driver 617.14 (32.0.16.1714)
CPU / RAM i7-13650HX / 32 GB
OS Windows 11 Pro, build 26300
Mode Series X

The laptop also has an Intel UHD iGPU. victory.exe needed the
"high performance" GPU preference, or the default adapter would have been
the iGPU (host.rs creates the device on the default adapter).

Summary

Stage Result
Boot, first-boot screens, intro video, start screen works, 30 fps (same as on the RX 6700 XT)
Loading into the world works
First mission's intro the title card renders, the scene stays black, the dialogue audio plays; the GPU hangs during or at the end of the dialogue (DXGI_ERROR_DEVICE_HUNG)

I ran it 7 times: release, diagnostics, debug layer, loop limit and GPU
timing. Every run that reached the world ended in a device removal.

1. Video memory is full in the world

I sampled \GPU Process Memory(pid_*)\Dedicated Usage once per second
(run 7):

Moment Dedicated (title process) Shared
Menus 4.45 GB 0.7 GB
Entering the world > 7.0 GB within seconds rising
Intro, until the hang flat at 7.0-7.2 GB (the budget on an 8 GB card) up to 7.0 GB
  • No list took 300 ms or more before dedicated usage reached 7 GB. After
    that, 51 did.
  • With VICTORY_GPU_TIMING=1, the slowest lists spend almost all their time
    outside their commands. The list in flight at the hang took 5,910 ms
    for 173 commands. Another took 6,772 ms for 246 commands, and its six
    slowest commands took ≤ 0.1 ms each.

Time a list spends outside its commands is what paging under
oversubscription looks like. One caveat: VRAM fills at the same moment the
world's work starts, so this run alone does not separate the two. A
comparison on a card with more memory (12 GB+) would settle it.

2. 134 pipelines refused: wave64 compute shaders on a wave32 GPU

host pipeline refused error=Paramètre incorrect. (0x80070057) comes up 116
to 134 times per run. The debug layer gives the reason:

ID3D12Device::CreateComputeShader: Shader wants wave lane count of 64 but
maximum wave lane count for device is 32. [id=622]

This is the README's "some compute programs need a GPU with 64-lane
waves". Here is the count on NVIDIA, where all of them are lost.

3. The shader-visible view heap is capped at 1,000,000

D3D12_DESCRIPTOR_HEAP_DESC.NumDescriptors 1507328, but the limit for shader
visible view heaps is 1000000 [id=645]
host view heap capped at 1000000

After this cap, I see a draw or dispatch dropped: no dynamic slots for its tables (15 in one run) and no free dynamic descriptor slots.

4. Slow indirect compute dispatches

These are from VICTORY_GPU_TIMING=1 (run 6), by total time:

Pipeline Times Total Max
compute c7feccae4e01e454 (indirect) 43 9.3 s 561 ms
compute 84eafa50504bc9ef (indirect) 32 3.5 s 267 ms
compute 8bbcbda6008eaa37 (indirect) 19 2.4 s 212 ms
mesh 5a801f1f568c7abd 6 1.7 s 350 ms

5. Ruled out

  • Shader loops: with VICTORY_SHADER_LOOP_LIMIT=4096 the hang stays. The
    median slow submission drops (≈430 → 267 ms), but the peaks do not
    (5.8 s).
  • A single faulting draw: DRED stops on a different draw each run (mesh
    2ee026ab4e20bbd5, 857b2e13c9cc107f, d62bc405f614313a,
    5d6f6107c4638db6, vertex e38865315b050ed9), at a different time
    each run. The removal is always DXGI_ERROR_DEVICE_HUNG (0x887A0006), and
    no DRED report has a GPU page fault in it. That fits a timeout, not one
    bad command.
  • The indirect state fix (#1507): a control run without it hung even
    sooner.

Other warnings seen

  • method not implemented object="device", slots 0x218 and 0x1c8
  • texture to buffer copies not implemented
  • view the host does not allow unordered=true format=53
  • ClearRenderTargetView: The clear values do not match those passed to resource creation [id=820]
**@⁠Bladureau** on GitHub · 2026-11-24 18:36 UTC · [original](https://github.com/Marvisak/VIctory/issues/1508) ## Setup | | | |---|---| | Commit | `ffe310e` (and #1507 for the indirect state fix) | | GPU | NVIDIA GeForce RTX 4060 Laptop, **8 GB**, driver 617.14 (32.0.16.1714) | | CPU / RAM | i7-13650HX / 32 GB | | OS | Windows 11 Pro, build 26300 | | Mode | Series X | The laptop also has an Intel UHD iGPU. `victory.exe` needed the "high performance" GPU preference, or the default adapter would have been the iGPU (`host.rs` creates the device on the default adapter). ## Summary | Stage | Result | |---|---| | Boot, first-boot screens, intro video, start screen | works, **30 fps** (same as on the RX 6700 XT) | | Loading into the world | works | | First mission's intro | the title card renders, the scene stays black, the dialogue audio plays; the GPU hangs during or at the end of the dialogue (`DXGI_ERROR_DEVICE_HUNG`) | I ran it 7 times: release, diagnostics, debug layer, loop limit and GPU timing. Every run that reached the world ended in a device removal. ## 1. Video memory is full in the world I sampled `\GPU Process Memory(pid_*)\Dedicated Usage` once per second (run 7): | Moment | Dedicated (title process) | Shared | |---|---|---| | Menus | 4.45 GB | 0.7 GB | | Entering the world | > 7.0 GB within seconds | rising | | Intro, until the hang | flat at 7.0-7.2 GB (the budget on an 8 GB card) | up to 7.0 GB | * **No list took 300 ms or more before dedicated usage reached 7 GB.** After that, 51 did. * With `VICTORY_GPU_TIMING=1`, the slowest lists spend almost all their time **outside their commands**. The list in flight at the hang took 5,910 ms for 173 commands. Another took 6,772 ms for 246 commands, and its six slowest commands took ≤ 0.1 ms each. Time a list spends outside its commands is what paging under oversubscription looks like. One caveat: VRAM fills at the same moment the world's work starts, so this run alone does not separate the two. A comparison on a card with more memory (12 GB+) would settle it. ## 2. 134 pipelines refused: wave64 compute shaders on a wave32 GPU `host pipeline refused error=Paramètre incorrect. (0x80070057)` comes up 116 to 134 times per run. The debug layer gives the reason: ``` ID3D12Device::CreateComputeShader: Shader wants wave lane count of 64 but maximum wave lane count for device is 32. [id=622] ``` This is the README's "some compute programs need a GPU with 64-lane waves". Here is the count on NVIDIA, where all of them are lost. ## 3. The shader-visible view heap is capped at 1,000,000 ``` D3D12_DESCRIPTOR_HEAP_DESC.NumDescriptors 1507328, but the limit for shader visible view heaps is 1000000 [id=645] host view heap capped at 1000000 ``` After this cap, I see `a draw or dispatch dropped: no dynamic slots for its tables` (15 in one run) and `no free dynamic descriptor slots`. ## 4. Slow indirect compute dispatches These are from `VICTORY_GPU_TIMING=1` (run 6), by total time: | Pipeline | Times | Total | Max | |---|---|---|---| | compute `c7feccae4e01e454` (indirect) | 43 | 9.3 s | 561 ms | | compute `84eafa50504bc9ef` (indirect) | 32 | 3.5 s | 267 ms | | compute `8bbcbda6008eaa37` (indirect) | 19 | 2.4 s | 212 ms | | mesh `5a801f1f568c7abd` | 6 | 1.7 s | 350 ms | ## 5. Ruled out * **Shader loops:** with `VICTORY_SHADER_LOOP_LIMIT=4096` the hang stays. The median slow submission drops (≈430 → 267 ms), but the peaks do not (5.8 s). * **A single faulting draw:** DRED stops on a different draw each run (mesh `2ee026ab4e20bbd5`, `857b2e13c9cc107f`, `d62bc405f614313a`, `5d6f6107c4638db6`, vertex `e38865315b050ed9`), at a different time each run. The removal is always `DXGI_ERROR_DEVICE_HUNG` (0x887A0006), and no DRED report has a GPU page fault in it. That fits a timeout, not one bad command. * **The indirect state fix (#1507):** a control run without it hung even sooner. ## Other warnings seen * `method not implemented object="device"`, slots `0x218` and `0x1c8` * `texture to buffer copies not implemented` * `view the host does not allow unordered=true format=53` * `ClearRenderTargetView: The clear values do not match those passed to resource creation` [id=820]
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:34:29 +00:00
Author
Owner

@⁠Bladureau on GitHub · 2026-11-24 19:05 UTC · original

Correction, and descriptor heap measurements (NVIDIA cap)

Correction to section 3 above. I wrote "15 dropped draws in one run".
That was the number of log lines. The dropped= counter is only logged at
powers of two, so 15 lines mean ≥ 16,384 dropped draws. Across 9 runs, the
highest logged value was between 512 and 65,536 per run. Each run reaches
no free dynamic descriptor slots in the world.

I added diagnostics-only counters to descriptor::host and draw.rs (local
branch, not proposed) and ran into the first mission's intro twice more on
the RTX 4060 Laptop. The host keeps 934,464 of the title's 1,245,184 view
slots (1,000,000 − 2^16 dynamic).

What takes the dynamic slots

Fresh tables, by reason Tables Of them reused in the list Dynamic slots taken
holding a constant buffer 196,503 53,339 799,198 (98 %)
reaching past the capped heap only (index >= host.count()) 8,192 883 15,299 (2 %)

The title does reach past the cap, but only through tables, which
tables() makes afresh. That is why title slot past the host heap
(mirror) never fired. Constant buffer tables take almost all the slots.

How many dynamic slots one frame needs

2^16 slots (stock, capped heap) 180,224 slots (experiment below)
Most taken at once 65,536 (reached within 5 s of entering the world) between 65,539 and 131,071
Failed runs / dropped draws ≥ 8,192 / ≥ 8,192 0 / 0
  • The stock failures are real exhaustion. 0 to 200 slots are still free
    when they happen.
  • Fragmentation hurts large tables: one request for 254 slots failed
    with 5,162 free, but the longest free run was 46.
  • One frame's lists need more than 2^16 slots, and 2^17 would have been
    enough in this run.

The title's own slots

Slots (64Ki buckets) Used
0 – 131,071 (buckets 0–1) 111k – 127k, growing
131,072 – 327,679 (buckets 2–4) 0 in both runs
327,680 – 934,463 (buckets 5–14) 330 to 8,407 per bucket, sparse
  • Distinct title slots that held a view: about 131k – 146k, so the slots
    are sparse, but tables read up to 934,156.
  • The kept range cannot shrink.

Experiment: dynamic slots in the unused buckets

VICTORY_DYNAMIC_HOLE=147456,180224 moves a capped heap's dynamic range
into title slots 147,456 – 327,679, and counts any title slot written or
read there. The result: 0 conflicts, 0 failures, 0 dropped draws. The
scene still stays black. The world's GPU hang is unchanged: it still comes
during the intro, with the same slow submissions (median ≈ 450 ms, max ≈
6 s). So the exhaustion costs draws but is not what hangs this GPU, nor
what keeps the scene black here. VRAM (above) is still the main suspect.

Options

A. As in the experiment, a dynamic range in title slots the title does
not use. It is not safe as it stands: the title's low region grows towards
it, so this needs conflict detection and moving slots out.

B. More reuse of identical tables. It already saves about a quarter of
constant buffer tables.

C. Release dynamic slots when the list that took them has run, not
when the submission has. Peaks are per submission today.

D. Remap the title's sparse slots. This means translating indices in
the shaders.

Which direction would you take? I can write it and test it here, since this
path only runs on capped (NVIDIA) heaps.

**@⁠Bladureau** on GitHub · 2026-11-24 19:05 UTC · [original](https://github.com/Marvisak/VIctory/issues/1508#issuecomment-7141575428) ## Correction, and descriptor heap measurements (NVIDIA cap) **Correction to section 3 above.** I wrote "15 dropped draws in one run". That was the number of log lines. The `dropped=` counter is only logged at powers of two, so 15 lines mean ≥ 16,384 dropped draws. Across 9 runs, the highest logged value was between 512 and 65,536 per run. Each run reaches `no free dynamic descriptor slots` in the world. I added diagnostics-only counters to `descriptor::host` and `draw.rs` (local branch, not proposed) and ran into the first mission's intro twice more on the RTX 4060 Laptop. The host keeps 934,464 of the title's 1,245,184 view slots (1,000,000 − 2^16 dynamic). ### What takes the dynamic slots | Fresh tables, by reason | Tables | Of them reused in the list | Dynamic slots taken | |---|---|---|---| | holding a constant buffer | 196,503 | 53,339 | **799,198 (98 %)** | | reaching past the capped heap only (`index >= host.count()`) | 8,192 | 883 | 15,299 (2 %) | The title does reach past the cap, but only through tables, which `tables()` makes afresh. That is why `title slot past the host heap` (`mirror`) never fired. Constant buffer tables take almost all the slots. ### How many dynamic slots one frame needs | | 2^16 slots (stock, capped heap) | 180,224 slots (experiment below) | |---|---|---| | Most taken at once | 65,536 (reached within 5 s of entering the world) | **between 65,539 and 131,071** | | Failed runs / dropped draws | ≥ 8,192 / ≥ 8,192 | **0 / 0** | * **The stock failures are real exhaustion.** 0 to 200 slots are still free when they happen. * **Fragmentation hurts large tables:** one request for 254 slots failed with 5,162 free, but the longest free run was 46. * **One frame's lists need more than 2^16 slots, and 2^17 would have been enough in this run.** ### The title's own slots | Slots (64Ki buckets) | Used | |---|---| | 0 – 131,071 (buckets 0–1) | 111k – 127k, growing | | 131,072 – 327,679 (buckets 2–4) | **0** in both runs | | 327,680 – 934,463 (buckets 5–14) | 330 to 8,407 per bucket, sparse | * **Distinct title slots that held a view:** about 131k – 146k, so the slots are sparse, but tables read up to 934,156. * **The kept range cannot shrink.** ### Experiment: dynamic slots in the unused buckets `VICTORY_DYNAMIC_HOLE=147456,180224` moves a capped heap's dynamic range into title slots 147,456 – 327,679, and counts any title slot written or read there. The result: **0 conflicts, 0 failures, 0 dropped draws.** The scene still stays black. The world's GPU hang is unchanged: it still comes during the intro, with the same slow submissions (median ≈ 450 ms, max ≈ 6 s). So the exhaustion costs draws but is not what hangs this GPU, nor what keeps the scene black here. VRAM (above) is still the main suspect. ### Options **A.** As in the experiment, a dynamic range in title slots the title does not use. It is not safe as it stands: the title's low region grows towards it, so this needs conflict detection and moving slots out. **B.** More reuse of identical tables. It already saves about a quarter of constant buffer tables. **C.** Release dynamic slots when the list that took them has run, not when the submission has. Peaks are per submission today. **D.** Remap the title's sparse slots. This means translating indices in the shaders. Which direction would you take? I can write it and test it here, since this path only runs on capped (NVIDIA) heaps.
Author
Owner

@⁠Bladureau on GitHub · 2026-11-24 19:48 UTC · original

Correction: VRAM is not the cause of the hang, wave64 programs are

In section 1 of this report, I named full video memory as the most likely cause of the world's GPU hang on this card. A test of #578 shows that is wrong. With #578 merged onto main ffe310e, the title ran 579 s in the world without a device removal, and I closed it. For 360 s of that run, the title used 7.0–7.2 GB of dedicated memory, as it did before. Without #578, all 10 earlier world runs ended in a device removal, the plain-main ones 38–217 s in. Details are on #578.

So the hang here is the one in #778: wave64 programs running on 32-lane waves. That also fits the DRED reports in this issue, which always stopped in mesh draws.

I also missed several open reports and PRs that cover this one:

  • #735: the same GPU (RTX 4060 Laptop), with the same 1M heap cap.
  • #747: the 2^16 dynamic slots on capped heaps, with measurements at 2^18. Fixes are proposed in #1349, #1548 and #949.
  • #548 and #334: the title buffer left in UNORDERED_ACCESS by indirect.rs (debug layer ids 527 and 538). #334 is a more complete fix than my #1507 and #1527.
  • #778 and #578: the hang itself.

The measurements above (wave64 pipelines refused, descriptor slot use) still hold. I will test the related PRs on this card rather than open new ones.

**@⁠Bladureau** on GitHub · 2026-11-24 19:48 UTC · [original](https://github.com/Marvisak/VIctory/issues/1508#issuecomment-7142608946) ## Correction: VRAM is not the cause of the hang, wave64 programs are In section 1 of this report, I named full video memory as the most likely cause of the world's GPU hang on this card. **A test of #578 shows that is wrong.** With #578 merged onto `main` `ffe310e`, the title ran 579 s in the world without a device removal, and I closed it. For 360 s of that run, the title used 7.0–7.2 GB of dedicated memory, as it did before. Without #578, all 10 earlier world runs ended in a device removal, the plain-`main` ones 38–217 s in. Details are on #578. So the hang here is the one in #778: wave64 programs running on 32-lane waves. That also fits the DRED reports in this issue, which always stopped in mesh draws. I also missed several open reports and PRs that cover this one: - **#735:** the same GPU (RTX 4060 Laptop), with the same 1M heap cap. - **#747:** the 2^16 dynamic slots on capped heaps, with measurements at 2^18. Fixes are proposed in #1349, #1548 and #949. - **#548 and #334:** the title buffer left in `UNORDERED_ACCESS` by `indirect.rs` (debug layer ids 527 and 538). #334 is a more complete fix than my #1507 and #1527. - **#778 and #578:** the hang itself. The measurements above (wave64 pipelines refused, descriptor slot use) still hold. I will test the related PRs on this card rather than open new ones.
Author
Owner

@⁠Marvisak on GitHub · 2026-11-25 10:23 UTC · original

Automated triage for the maintainers.

Complete run report (RTX 4060 Laptop 8 GB, driver 617.14, Windows 11 26300, ffe310e): world entry works, the first mission's scene stays black, then DXGI_ERROR_DEVICE_HUNG in mesh draws. Thanks for the corrections and the A/B.

  • The hang: with #578, the world ran 579 s with no removal, so this is the wave64 mesh hang tracked in #778 (#578 is rebased as #1922). The NVIDIA world hang overall is in #71.
  • Wave64 compute refused: Lower::new in crates/victory-shader/src/emit/lower.rs declares WaveSize(64) for wave64 programs that depend on the lane layout, and a 32-lane GPU refuses them. Open PRs: #189, #1929, #1922, #1960.
  • Capped view heap and dynamic slots: HostHeap::new in crates/victory-gpu/src/descriptor/host.rs takes 2^16 dynamic slots on a capped heap. Tracked in #747 (PRs #1349, #1548). That is the place to discuss the remap options.
  • VRAM: open PR #2143 links this report.
  • Hybrid laptops: host.rs creates the device on the default adapter (D3D12CreateDevice(None, ...)). Open PRs #2146 and #1630 add adapter choice.

Generated by Claude Code

**@⁠Marvisak** on GitHub · 2026-11-25 10:23 UTC · [original](https://github.com/Marvisak/VIctory/issues/1508#issuecomment-7159623382) <!-- victory-issue-triage v1 verdict=tracked seen=2026-11-24T19:48:07Z at=2026-11-25T09:50:38Z --> Automated triage for the maintainers. Complete run report (RTX 4060 Laptop 8 GB, driver 617.14, Windows 11 26300, `ffe310e`): world entry works, the first mission's scene stays black, then `DXGI_ERROR_DEVICE_HUNG` in mesh draws. Thanks for the corrections and the A/B. - **The hang:** with #578, the world ran 579 s with no removal, so this is the wave64 mesh hang tracked in #778 (#578 is rebased as #1922). The NVIDIA world hang overall is in #71. - **Wave64 compute refused:** `Lower::new` in `crates/victory-shader/src/emit/lower.rs` declares `WaveSize(64)` for wave64 programs that depend on the lane layout, and a 32-lane GPU refuses them. Open PRs: #189, #1929, #1922, #1960. - **Capped view heap and dynamic slots:** `HostHeap::new` in `crates/victory-gpu/src/descriptor/host.rs` takes 2^16 dynamic slots on a capped heap. Tracked in #747 (PRs #1349, #1548). That is the place to discuss the remap options. - **VRAM:** open PR #2143 links this report. - **Hybrid laptops:** `host.rs` creates the device on the default adapter (`D3D12CreateDevice(None, ...)`). Open PRs #2146 and #1630 add adapter choice. --- _Generated by [Claude Code](https://claude.ai/code)_
Author
Owner

@⁠potatoe0100 on GitHub · 2026-11-26 14:11 UTC · original

#2143, the VRAM PR linked above, has merged as e04c078. It stops programs' constant tables covering their whole code, which was costing GBs of NVIDIA video memory. It was measured under vkd3d-proton on an RTX 5080, so whether it changes native D3D12 usage on an 8 GB card is still open.

AI-assisted (Claude)

**@⁠potatoe0100** on GitHub · 2026-11-26 14:11 UTC · [original](https://github.com/Marvisak/VIctory/issues/1508#issuecomment-7194411885) #2143, the VRAM PR linked above, has merged as e04c078. It stops programs' constant tables covering their whole code, which was costing GBs of NVIDIA video memory. It was measured under vkd3d-proton on an RTX 5080, so whether it changes native D3D12 usage on an 8 GB card is still open. AI-assisted (Claude)
This discussion has been locked. Commenting is limited to contributors.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
github/Marvisak--VIctory#1508
No description provided.