Slot eviction: what it did is in the frame-rate lines (#955) #972

Manually merged
github merged 1 commit from github-bot/gh-972 into main 2026-11-29 08:22:03 +00:00 AGit
Owner

@⁠kibagami-nc on GitHub · 2026-11-28 10:24 UTC · original
kibagami-nc:diag/slot-eviction-line → main · +65 −0 · 2 files · 1 commits · merged 2026-11-29 08:16 UTC

Why

VICTORY_SLOT_EVICT=1 has been on in the launchers since v2026.11.28.01, with the rest of the memory stack. Above 85% of the card's budget, it lets go of the host copies of idle textures, although title slots still show them, until the card is under 75%. A texture drawn again is then made and uploaded again.

slot_evict keeps counts of all that in SLOT_EVICT and SLOT_STATE:

  • copies let go, and their bytes;
  • slots put back to waiting;
  • textures made again, and of them those back within 2 s (let go too soon);
  • the time they were away;
  • passes given up because a draw used the texture meanwhile.

Nothing reads those counts. They are kept but written nowhere, and the one note it makes goes only to the in-memory trail. So a log cannot tell whether eviction was at work while textures came and went. #955 is such a report: textures glitching every 2 seconds "with the latest version", on an RTX 3060 12 GB.

The change

resource::slot_evict_line, called with the other frame-rate lines, writes them with VICTORY_SLOT_EVICT=1. It writes only for a second in which something was let go, put back to waiting, made again or given up, so a run without pressure gets no new line:

slot eviction since the last line (VICTORY_SLOT_EVICT=1): 3 host copies of textures let go though slots showed them (12.0 MB), 7 slots put back to waiting; 2 let go before and made again, 1 of them within 2 s (let go too soon), away 2.5 s on average; 1 given up as a draw used the texture meanwhile. Evicting: yes; of the last 40 idle-looking textures, 5 kept as a draw's table showed them, 2 not to be taken (a slot shaders pick by index shows them)

Nothing that eviction does changes.

Tests

  • New resource::tests::the_slot_eviction_line_tells_what_eviction_did:
    • nothing happened: no line;
    • every count lands where it belongs, including the average time away;
    • a second with textures only made again is still told.
  • cargo test -p victory-gpu --lib --locked: 454 passed, 36 ignored.
  • Clippy (-D warnings, default and --all-features): nothing in the changed lines. It stops on main's own manual_is_multiple_of (fixed in #665). With that lint allowed, both builds are clean.

Not run with the game. In a run like #955's, the line shows whether the glitches line up with copies let go too soon.

No game files, dumps or extracted data are included.

**@⁠kibagami-nc** on GitHub · 2026-11-28 10:24 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/972) `kibagami-nc:diag/slot-eviction-line` → `main` · +65 −0 · 2 files · 1 commits · merged 2026-11-29 08:16 UTC ## Why `VICTORY_SLOT_EVICT=1` has been on in the launchers since v2026.11.28.01, with the rest of the memory stack. Above 85% of the card's budget, it lets go of the host copies of idle textures, although title slots still show them, until the card is under 75%. A texture drawn again is then made and uploaded again. `slot_evict` keeps counts of all that in `SLOT_EVICT` and `SLOT_STATE`: - copies let go, and their bytes; - slots put back to waiting; - textures made again, and of them those back within 2 s (let go too soon); - the time they were away; - passes given up because a draw used the texture meanwhile. Nothing reads those counts. They are kept but written nowhere, and the one note it makes goes only to the in-memory trail. So a log cannot tell whether eviction was at work while textures came and went. #955 is such a report: textures glitching every 2 seconds "with the latest version", on an RTX 3060 12 GB. ## The change `resource::slot_evict_line`, called with the other frame-rate lines, writes them with `VICTORY_SLOT_EVICT=1`. It writes only for a second in which something was let go, put back to waiting, made again or given up, so a run without pressure gets no new line: ``` slot eviction since the last line (VICTORY_SLOT_EVICT=1): 3 host copies of textures let go though slots showed them (12.0 MB), 7 slots put back to waiting; 2 let go before and made again, 1 of them within 2 s (let go too soon), away 2.5 s on average; 1 given up as a draw used the texture meanwhile. Evicting: yes; of the last 40 idle-looking textures, 5 kept as a draw's table showed them, 2 not to be taken (a slot shaders pick by index shows them) ``` Nothing that eviction does changes. ## Tests - **New** `resource::tests::the_slot_eviction_line_tells_what_eviction_did`: - nothing happened: no line; - every count lands where it belongs, including the average time away; - a second with textures only made again is still told. - **`cargo test -p victory-gpu --lib --locked`**: 454 passed, 36 ignored. - **Clippy** (`-D warnings`, default and `--all-features`): nothing in the changed lines. It stops on `main`'s own `manual_is_multiple_of` (fixed in #665). With that lint allowed, both builds are clean. Not run with the game. In a run like #955's, the line shows whether the glitches line up with copies let go too soon. No game files, dumps or extracted data are included.
VICTORY_SLOT_EVICT=1, on in the launchers since v2026.11.28.01, lets go
of the host copies of idle textures above 85% of the card's budget. Its
counts (copies let go and their bytes, slots put back to waiting,
textures made again and those back within 2 s, the time they were away,
the passes given up) were kept but written nowhere: a log could not tell
whether it was at work while textures came and went (#955).

With the switch on, the frame-rate lines now tell it for every second
in which something was let go, put back, made again or given up, with
the last pass's state. Nothing is written while nothing happens.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-28 14:31:04 +00:00
Author
Owner

@⁠YUYING234 on GitHub · 2026-11-28 10:33 UTC · original

Two things from an 8 GB laptop on 63b902f, the second of which is a crash shape I have not seen before.

1. The 540p row does not help on 8 GB, and I think the reason matters

I ran the new SERIES S PICTURE at 960x540 (FASTEST) against the 1440p runs, same machine, same fresh save:

960x540 2560x1440 (earlier)
render / shown, median 14.0 / 27.0 fps 13.5 / 22.0 fps
VRAM peak 7,609 MiB 7,751 MiB
VRAM creep in ten minutes +740 MiB similar

So 141 MiB and about half a frame. The frame breakdown says why:

540p:   12.0 fps, 83.3 ms (preparing 23.9: copies 11.8 ms 61 MB, textures 1.0 ms; GPU 53.1; copy back 4.2 ms)
540p:   13.4 fps, 74.9 ms (preparing 34.4: copies 22.0 ms 87 MB, textures 1.6 ms; GPU 28.9; copy back 5.9 ms)
1440p:  15.0 fps, 66.6 ms (preparing 33.5: copies  8.4 ms 52 MB, textures 3.7 ms; GPU  5.8; copy back 55.7 ms)

The copying is 52-94 MB a frame at both sizes. Dropping the picture by 2.7x in each direction moved that by nothing, so the resolution row is not the lever on this card - the per-frame copy of title memory is. It also matches what you wrote in docs/findings.md for the 5080: the cost sits on our side of title memory, not on the card.

2. A crash after the first "Focus" on the boat, and the fence number is suspicious

What the player saw: fresh save, prologue, driving the boat, first use of Focus - the screen flickers, then all of the water disappears, the boat drops through the world, and the game exits.

What the log recorded:

ERROR victory_gpu::host: relay: fence 18446744073709551615 did not reach 312701;
      device removed: GPU 不响应更多的命令 (0x887A0006)

18446744073709551615 is u64::MAX - the fence value the relay read is 0 - 1, not a real one, so it could never reach 312701 and the wait could not end. I would guess at an underflow somewhere the relay takes one less than nothing (an empty batch, or a fence asked for before its first submission), but that is a guess from one number.

Two things made this one worse than the earlier device removals:

  • the process could not be killed afterwards - taskkill /F reports "no running instance" while the PID still exists, and the working set (10.9 GB) is never released;
  • nvidia-smi hangs afterwards, so the card itself is wedged, not just our process. A reboot is the only way out.

So the water vanishing is not a rendering choice that follows the crash: the water passes simply stop running when the fence wait never completes, and the title falls through the world because the water is what it was standing on.

The run it happened in

63b902f, Series S, VICTORY_MENU_RES=540, frame generation 2x, fresh save. VICTORY_RELAY=2 is my own setting (it has been in my launcher since before this build), so if the fence underflow needs the relay, that is where to look. 23 minutes in, VRAM 6.8 -> 7.8 GB, frame generation had fallen from 95 % of samples to 45 % in the last few minutes - which may be the same stall starting earlier and the crash being where it finished.

Happy to re-run with VICTORY_RELAY at its default if you would rather know whether the relay is needed for it, once the machine is back.

**@⁠YUYING234** on GitHub · 2026-11-28 10:33 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/972#issuecomment-7237968373) Two things from an 8 GB laptop on `63b902f`, the second of which is a crash shape I have not seen before. ## 1. The 540p row does not help on 8 GB, and I think the reason matters I ran the new `SERIES S PICTURE` at **960x540 (FASTEST)** against the 1440p runs, same machine, same fresh save: | | 960x540 | 2560x1440 (earlier) | |---|---|---| | render / shown, median | **14.0 / 27.0 fps** | 13.5 / 22.0 fps | | VRAM peak | **7,609 MiB** | 7,751 MiB | | VRAM creep in ten minutes | **+740 MiB** | similar | So 141 MiB and about half a frame. The frame breakdown says why: ``` 540p: 12.0 fps, 83.3 ms (preparing 23.9: copies 11.8 ms 61 MB, textures 1.0 ms; GPU 53.1; copy back 4.2 ms) 540p: 13.4 fps, 74.9 ms (preparing 34.4: copies 22.0 ms 87 MB, textures 1.6 ms; GPU 28.9; copy back 5.9 ms) 1440p: 15.0 fps, 66.6 ms (preparing 33.5: copies 8.4 ms 52 MB, textures 3.7 ms; GPU 5.8; copy back 55.7 ms) ``` The copying is **52-94 MB a frame at both sizes**. Dropping the picture by 2.7x in each direction moved that by nothing, so the resolution row is not the lever on this card - the per-frame copy of title memory is. It also matches what you wrote in `docs/findings.md` for the 5080: the cost sits on our side of title memory, not on the card. ## 2. A crash after the first "Focus" on the boat, and the fence number is suspicious What the player saw: fresh save, prologue, driving the boat, **first use of Focus** - the screen flickers, then **all of the water disappears**, the boat drops through the world, and the game exits. What the log recorded: ``` ERROR victory_gpu::host: relay: fence 18446744073709551615 did not reach 312701; device removed: GPU 不响应更多的命令 (0x887A0006) ``` **`18446744073709551615` is `u64::MAX`** - the fence value the relay read is `0 - 1`, not a real one, so it could never reach 312701 and the wait could not end. I would guess at an underflow somewhere the relay takes one less than nothing (an empty batch, or a fence asked for before its first submission), but that is a guess from one number. Two things made this one worse than the earlier device removals: - the process **could not be killed** afterwards - `taskkill /F` reports "no running instance" while the PID still exists, and the working set (10.9 GB) is never released; - **`nvidia-smi` hangs** afterwards, so the card itself is wedged, not just our process. A reboot is the only way out. So the water vanishing is not a rendering choice that follows the crash: the water passes simply stop running when the fence wait never completes, and the title falls through the world because the water is what it was standing on. ## The run it happened in `63b902f`, Series S, `VICTORY_MENU_RES=540`, frame generation 2x, fresh save. **`VICTORY_RELAY=2` is my own setting** (it has been in my launcher since before this build), so if the fence underflow needs the relay, that is where to look. 23 minutes in, VRAM 6.8 -> 7.8 GB, frame generation had fallen from 95 % of samples to 45 % in the last few minutes - which may be the same stall starting earlier and the crash being where it finished. Happy to re-run with `VICTORY_RELAY` at its default if you would rather know whether the relay is needed for it, once the machine is back.
Author
Owner

@⁠kibagami-nc on GitHub · 2026-11-28 10:51 UTC · original

Thanks for both. On the second, the number is not an underflow.

18446744073709551615 (u64::MAX) is what D3D12's GetCompletedValue returns for any fence once the device is removed. The relay already treats it so (fence_reached), and the line prints it as if it were a value. What happened is the second half: 0x887A0006, the card stopped responding and Windows reset it. Once that happens, every fence reads u64::MAX, so the water passes stopping and the fall through the world come after the hang, not before it.

The process that could not be killed and nvidia-smi hanging are the driver not coming back from that reset. That is between Windows and the driver, which is why only a reboot helped.

What made the card stop is the open question. Your note that frame generation fell from 95% to 45% of samples in the last minutes would fit something growing until it hangs. VICTORY_RELAY=2 is the launchers' default, so it is not a setting of yours apart from the defaults. A run without frame generation in the same place would tell whether it is part of it.

On your first point: yes, at 52 to 94 MB a frame the copy of title memory costs the same at both sizes, so the picture size is not the lever on that card.

**@⁠kibagami-nc** on GitHub · 2026-11-28 10:51 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/972#issuecomment-7238170755) Thanks for both. On the second, the number is not an underflow. `18446744073709551615` (`u64::MAX`) is what D3D12's `GetCompletedValue` returns for any fence once the device is removed. The relay already treats it so (`fence_reached`), and the line prints it as if it were a value. What happened is the second half: `0x887A0006`, the card stopped responding and Windows reset it. Once that happens, every fence reads `u64::MAX`, so the water passes stopping and the fall through the world come after the hang, not before it. The process that could not be killed and `nvidia-smi` hanging are the driver not coming back from that reset. That is between Windows and the driver, which is why only a reboot helped. What made the card stop is the open question. Your note that frame generation fell from 95% to 45% of samples in the last minutes would fit something growing until it hangs. `VICTORY_RELAY=2` is the launchers' default, so it is not a setting of yours apart from the defaults. A run without frame generation in the same place would tell whether it is part of it. On your first point: yes, at 52 to 94 MB a frame the copy of title memory costs the same at both sizes, so the picture size is not the lever on that card.
Author
Owner

@⁠YUYING234 on GitHub · 2026-11-28 11:02 UTC · original

Answering my own question from the comment above: I re-ran the same stretch with VICTORY_RELAY unset. It still crashes, but not with the fence.

VICTORY_RELAY=2 (mine) default (RELAY=1)
survived 23 min 14.6 min
error relay: fence 18446744073709551615 did not reach 312701 host GPU device removed after 4 submissions sent ahead (VICTORY_RELAY=1) of 41 lists
reason 0x887A0006 0x887A0004 and 0x887A0006
after the crash process unkillable, nvidia-smi hangs, reboot by power button exited cleanly

So:

  1. The crash is not the relay's. The same scene ends the same way at the default, so whatever the title does that the card cannot take is upstream of the relay.
  2. The fence underflow is a relay-2 bug of its own. u64::MAX for the fence value only appears with VICTORY_RELAY=2, and it is worse than the crash it accompanies: the process cannot be reaped (taskkill says no such instance while the PID holds 10 GB), and the card itself stops answering nvidia-smi, so the only way out is holding the power button. Even if the title crash is fixed, that one is worth having on the list.

What the panel said a moment before the default-relay crash:

FPS 13.2  FRAME 82.1 MS  LONGEST 118   FRAME GEN 2X  SHOWN 24.4
DRAWS 2994  DROPPED 242
SUBMIT BUSY 40.7  WAITS FOR GPU 31.8
GPU BUSY 54.7  IDLE BEHIND US 19.8
VRAM 6.8/6.4 GB   SHARED 7.9

That is 400 MiB over the budget with 7.9 GB of the PC's memory shared with the card, the same shape as every other crash tonight (7.7-7.8 GB peaks on all of them). Both runs sat there for minutes before ending, so it is not a spike that kills it.

I can run the same stretch with VICTORY_MEMORY_CARD_MB or the 540p row and the relay at default if you want the memory side of this narrowed while the crash itself is being worked out - say which and I will.

**@⁠YUYING234** on GitHub · 2026-11-28 11:02 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/972#issuecomment-7238281542) Answering my own question from the comment above: I re-ran the same stretch with **`VICTORY_RELAY` unset**. It still crashes, but not with the fence. | | `VICTORY_RELAY=2` (mine) | **default (`RELAY=1`)** | |---|---|---| | survived | 23 min | **14.6 min** | | error | **`relay: fence 18446744073709551615 did not reach 312701`** | `host GPU device removed after 4 submissions sent ahead (VICTORY_RELAY=1) of 41 lists` | | reason | `0x887A0006` | `0x887A0004` and `0x887A0006` | | after the crash | process unkillable, `nvidia-smi` hangs, **reboot by power button** | exited cleanly | So: 1. **The crash is not the relay's.** The same scene ends the same way at the default, so whatever the title does that the card cannot take is upstream of the relay. 2. **The fence underflow is a relay-2 bug of its own.** `u64::MAX` for the fence value only appears with `VICTORY_RELAY=2`, and it is worse than the crash it accompanies: the process cannot be reaped (`taskkill` says no such instance while the PID holds 10 GB), and the card itself stops answering `nvidia-smi`, so the only way out is holding the power button. Even if the title crash is fixed, that one is worth having on the list. What the panel said a moment before the default-relay crash: ``` FPS 13.2 FRAME 82.1 MS LONGEST 118 FRAME GEN 2X SHOWN 24.4 DRAWS 2994 DROPPED 242 SUBMIT BUSY 40.7 WAITS FOR GPU 31.8 GPU BUSY 54.7 IDLE BEHIND US 19.8 VRAM 6.8/6.4 GB SHARED 7.9 ``` That is 400 MiB over the budget with 7.9 GB of the PC's memory shared with the card, the same shape as every other crash tonight (7.7-7.8 GB peaks on all of them). Both runs sat there for minutes before ending, so it is not a spike that kills it. I can run the same stretch with `VICTORY_MEMORY_CARD_MB` or the 540p row and the relay at default if you want the memory side of this narrowed while the crash itself is being worked out - say which and I will.
Author
Owner

@⁠kibagami-nc on GitHub · 2026-11-28 11:20 UTC · original

Thanks, that pair of runs is useful. One detail: victory.exe play sets VICTORY_RELAY=2 itself, so 2 is what most people run, and your earlier runs were on the launchers' default. The layer's own default, when nothing sets it, is 1, which is what your second run had.

On what you found:

  • The crash is not the relay's. It ends the same way with either relay.
  • The process that could not be killed is one run each way, so not proven yet. A process that taskkill cannot end is stuck inside the driver, and nvidia-smi hanging says the driver itself did not come back from the reset. The relay's thread waits in an ordinary wait that can be killed. If it happens again with relay 2 and never with 1, that would be worth its own issue.
  • The common factor in every crash tonight is memory: VRAM 6.8 GB of a 6.4 GB budget, and 7.9 GB of the PC's memory shared with the card. Past the budget, Windows pages the card's memory in and out, and a frame can then take long enough for the card to be reset.

So the memory test is the one I would run: the same stretch, relay at default, with VICTORY_TEXTURE_ROOM_PERCENT=70 in victory-settings.txt (with frame generation on, the launcher sets 80). If the card stays under its budget and the run survives, the hang is the memory.

**@⁠kibagami-nc** on GitHub · 2026-11-28 11:20 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/972#issuecomment-7238491860) Thanks, that pair of runs is useful. One detail: `victory.exe play` sets `VICTORY_RELAY=2` itself, so 2 is what most people run, and your earlier runs were on the launchers' default. The layer's own default, when nothing sets it, is 1, which is what your second run had. On what you found: - **The crash is not the relay's.** It ends the same way with either relay. - **The process that could not be killed** is one run each way, so not proven yet. A process that `taskkill` cannot end is stuck inside the driver, and `nvidia-smi` hanging says the driver itself did not come back from the reset. The relay's thread waits in an ordinary wait that can be killed. If it happens again with relay 2 and never with 1, that would be worth its own issue. - **The common factor** in every crash tonight is memory: VRAM 6.8 GB of a 6.4 GB budget, and 7.9 GB of the PC's memory shared with the card. Past the budget, Windows pages the card's memory in and out, and a frame can then take long enough for the card to be reset. So the memory test is the one I would run: the same stretch, relay at default, with `VICTORY_TEXTURE_ROOM_PERCENT=70` in `victory-settings.txt` (with frame generation on, the launcher sets 80). If the card stays under its budget and the run survives, the hang is the memory.
Author
Owner

@⁠YUYING234 on GitHub · 2026-11-28 11:21 UTC · original

Two corrections to what I wrote above, both my mistake, and one of them changes the conclusion.

1. My "540p" numbers were not 540p

The Series S picture row is read from victory-settings.txt (play.rs, saved("VICTORY_MENU_S_RES")), not from the environment, and I had been passing VICTORY_MENU_RES - which is the Series X key. So the run I reported as 960x540 was in fact the default 720p / QUALITY (scene at the quality scale (0.6666667) in its log). The comparison I gave you was 720p against 1440p, not 540p.

The real 960x540 (performance, 0.5 scale), on the default launch settings:

960x540 + PERFORMANCE
render / shown, median 13.0 / 24.0 fps
frame generation working 86 % of samples
VRAM first -> last, peak 7,238 -> 7,816, peak 7,830 MiB
surviving 11 minutes

Peak is the same 7.8 GB as every other configuration tonight. So the conclusion holds but for a better reason than I had: at 960x540 the card still ends up 1.4 GB over its budget, and the frame rate is no better than at 1440p - the per-frame copy volume (52-94 MB) does not care about the picture size.

2. The fence underflow is not specific to VICTORY_RELAY=2

I said it was, because my control run at the default produced the generic device removed after N submissions instead. This run settles it the other way:

14:21:14  relay: fence 18446744073709551615 did not reach 142298; device removed (0x887A0006)

and the log for that same run says VICTORY_RELAY=1 throughout (the relay per frame (VICTORY_RELAY=1): 2.1 flights landed...). So the fence underflow happens at the default relay too - it is a bug in the relay's fence accounting itself, not one that needs relay-2 to show up. What differs between the two runs is which of the two failures gets reported first, not whether the relay is involved.

Where this leaves the crash

Every crash tonight has been at the same place and the same state:

  • boat, first use of Focus (the prompt 进入专注状态 以找到包裹 is on screen, then it goes),
  • VRAM 7.7-7.8 GB against a 5.2-6.4 GB budget with 5.8-7.9 GB of the PC's memory shared with the card,
  • frame generation dropping out in the seconds before (OFF in the frame captured a second before this one, 86 % of samples overall).

Five configurations, five crashes: 1440p, 1080to1440p, 960x540, relay 1 and relay 2. I have not found a setting that avoids it, and I do not think there is one on this card until the memory side is solved - the picture size only changes how much of the hurt is in the render pass.

**@⁠YUYING234** on GitHub · 2026-11-28 11:21 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/972#issuecomment-7238500323) Two corrections to what I wrote above, both my mistake, and one of them changes the conclusion. ## 1. My "540p" numbers were not 540p The Series S picture row is read from `victory-settings.txt` (`play.rs`, `saved("VICTORY_MENU_S_RES")`), not from the environment, and I had been passing `VICTORY_MENU_RES` - which is the Series X key. So the run I reported as 960x540 was in fact the default **720p / QUALITY** (`scene at the quality scale (0.6666667)` in its log). The comparison I gave you was 720p against 1440p, not 540p. **The real 960x540 (performance, 0.5 scale), on the default launch settings:** | | 960x540 + PERFORMANCE | |---|---| | render / shown, median | **13.0 / 24.0 fps** | | frame generation working | 86 % of samples | | VRAM first -> last, peak | 7,238 -> 7,816, **peak 7,830 MiB** | | surviving | 11 minutes | Peak is the same 7.8 GB as every other configuration tonight. So the conclusion holds but for a better reason than I had: **at 960x540 the card still ends up 1.4 GB over its budget**, and the frame rate is no better than at 1440p - the per-frame copy volume (52-94 MB) does not care about the picture size. ## 2. The fence underflow is not specific to `VICTORY_RELAY=2` I said it was, because my control run at the default produced the generic `device removed after N submissions` instead. This run settles it the other way: ``` 14:21:14 relay: fence 18446744073709551615 did not reach 142298; device removed (0x887A0006) ``` and the log for that same run says `VICTORY_RELAY=1` throughout (`the relay per frame (VICTORY_RELAY=1): 2.1 flights landed...`). So the fence underflow happens at the default relay too - it is a bug in the relay's fence accounting itself, not one that needs relay-2 to show up. What differs between the two runs is which of the two failures gets reported first, not whether the relay is involved. ## Where this leaves the crash Every crash tonight has been at the same place and the same state: - **boat, first use of Focus** (the prompt `进入专注状态 以找到包裹` is on screen, then it goes), - **VRAM 7.7-7.8 GB against a 5.2-6.4 GB budget** with 5.8-7.9 GB of the PC's memory shared with the card, - frame generation dropping out in the seconds before (OFF in the frame captured a second before this one, 86 % of samples overall). Five configurations, five crashes: 1440p, 1080to1440p, 960x540, relay 1 and relay 2. I have not found a setting that avoids it, and I do not think there is one on this card until the memory side is solved - the picture size only changes how much of the hurt is in the render pass.
Author
Owner

@⁠kibagami-nc on GitHub · 2026-11-28 11:50 UTC · original

Thanks for the corrections. The 540p run settles that the picture size is not the lever on that card.

On the fence: that run fits the same explanation, not a bug in the relay's counting. u64::MAX is what every D3D12 fence reads once the device is removed, whatever the relay mode, so with relay 1 it shows the same way. Whichever wait first sees the removed device prints it. #993 changes the line to say the device was lost before that value, so the next log won't read as an underflow.

That leaves what you found: five configurations, the same place (the boat, the first Focus), and VRAM 1.4 GB or more over the card's budget every time. KIFIR4KK has been through a matrix of settings on the same card class in #1032 (summary on #946). With the #609 target and texture-room settings (Targets=1280, TexRoom=85%), their "no room" samples fell from about 90 to 3. That is the memory side to try on yours, at the default relay.

**@⁠kibagami-nc** on GitHub · 2026-11-28 11:50 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/972#issuecomment-7238815592) Thanks for the corrections. The 540p run settles that the picture size is not the lever on that card. On the fence: that run fits the same explanation, not a bug in the relay's counting. `u64::MAX` is what every D3D12 fence reads once the device is removed, whatever the relay mode, so with relay 1 it shows the same way. Whichever wait first sees the removed device prints it. #993 changes the line to say the device was lost before that value, so the next log won't read as an underflow. That leaves what you found: five configurations, the same place (the boat, the first Focus), and VRAM 1.4 GB or more over the card's budget every time. KIFIR4KK has been through a matrix of settings on the same card class in #1032 (summary on #946). With the `#609` target and texture-room settings (`Targets=1280`, `TexRoom=85%`), their "no room" samples fell from about 90 to 3. That is the memory side to try on yours, at the default relay.
Author
Owner

@⁠YUYING234 on GitHub · 2026-11-28 15:46 UTC · original

You are right and I withdraw the claim. I called it an underflow because the value looked like one; u64::MAX being what any fence reads after the device is removed is the simpler explanation and it needs no bug. Two runs printing different faces of the same removal is not evidence of a relay fault, and I should have asked what that value means before writing it up as a finding. #993's wording change is the right fix - "the device was lost before this value" says what happened.

On the memory side, I have the two switches and the line to check them against, so this is ready to run when the card is free:

  • VICTORY_CARD_ROOM_FOR_TARGETS_MB=1280 (default 3,072, clamped at 8,192)
  • VICTORY_TEXTURE_ROOM_PERCENT=85 (default 90, clamped 50-97)

Our baseline, from a Series S 626-balanced run on the 4060 Laptop, is this line:

the texture queue's room: 6150 MB in use - 630 MB free in texture blocks
  + 112 MB kept for card copies of title buffers
  + 1701 MB kept for render targets
  = 7333 MB against a line of 5205 MB (80.0 % of a budget of 6507 MB): no room, new textures wait

So the reserve is 1701 MB at that moment against a 3,072 MB cap, and the line we cross is 80.0 %, not 90 - the percent only replaces the formula when the variable is actually set. After the change I expect kept for render targets to fall to 1,280 or below and the parenthesis to read 85.0 %, which is how I will know the settings landed rather than assume it.

One caution I want to state before the result, so I do not repeat the mistake above: these two settings may pull against each other. Targets=1280 takes about 420 MB out of the reserve, but TexRoom=85 raises the line from the formula's 80 % to 85 % - 5,531 MB instead of 5,205 MB - which admits more textures, not fewer. KIFIR4KK's "no room" samples falling from 90 to 3 is a count of stalls avoided, and that is not the same measurement as a lower peak. Our crash is 0x887A0006 with the card at 7.7-7.8 GB, so whether fewer stalls helps it is something I do not know yet.

What I will report is both numbers per run: the peak VRAM, the no room count, and where the run ended. If the peak does not move, that is a result too and I will say so rather than reach for a third setting to make the story work.

Separately, and possibly relevant to the same 8 GB wall: on Leonida's Vulkan runtime (the recompiled tree, not this one) the same card renders the title's first-run pages at 53-59 fps with about 2 GB in use, against 7.7 GB here. Different backend and a different amount of the world loaded, so it is not a fair comparison yet - but it is a large enough gap that the memory figure here looks like something this path adds rather than something the title needs.

**@⁠YUYING234** on GitHub · 2026-11-28 15:46 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/972#issuecomment-7241727978) You are right and I withdraw the claim. I called it an underflow because the value looked like one; `u64::MAX` being what any fence reads after the device is removed is the simpler explanation and it needs no bug. Two runs printing different faces of the same removal is not evidence of a relay fault, and I should have asked what that value means before writing it up as a finding. #993's wording change is the right fix - "the device was lost before this value" says what happened. **On the memory side**, I have the two switches and the line to check them against, so this is ready to run when the card is free: - `VICTORY_CARD_ROOM_FOR_TARGETS_MB=1280` (default 3,072, clamped at 8,192) - `VICTORY_TEXTURE_ROOM_PERCENT=85` (default 90, clamped 50-97) Our baseline, from a Series S 626-balanced run on the 4060 Laptop, is this line: ``` the texture queue's room: 6150 MB in use - 630 MB free in texture blocks + 112 MB kept for card copies of title buffers + 1701 MB kept for render targets = 7333 MB against a line of 5205 MB (80.0 % of a budget of 6507 MB): no room, new textures wait ``` So the reserve is `1701 MB` at that moment against a 3,072 MB cap, and the line we cross is 80.0 %, not 90 - the percent only replaces the formula when the variable is actually set. After the change I expect `kept for render targets` to fall to 1,280 or below and the parenthesis to read `85.0 %`, which is how I will know the settings landed rather than assume it. One caution I want to state before the result, so I do not repeat the mistake above: **these two settings may pull against each other.** `Targets=1280` takes about 420 MB out of the reserve, but `TexRoom=85` raises the line from the formula's 80 % to 85 % - 5,531 MB instead of 5,205 MB - which admits *more* textures, not fewer. KIFIR4KK's "no room" samples falling from 90 to 3 is a count of stalls avoided, and that is not the same measurement as a lower peak. Our crash is `0x887A0006` with the card at 7.7-7.8 GB, so whether fewer stalls helps it is something I do not know yet. What I will report is both numbers per run: the peak VRAM, the `no room` count, and where the run ended. If the peak does not move, that is a result too and I will say so rather than reach for a third setting to make the story work. Separately, and possibly relevant to the same 8 GB wall: on Leonida's Vulkan runtime (the recompiled tree, not this one) the same card renders the title's first-run pages at 53-59 fps with **about 2 GB** in use, against 7.7 GB here. Different backend and a different amount of the world loaded, so it is not a fair comparison yet - but it is a large enough gap that the memory figure here looks like something this path adds rather than something the title needs.
github manually merged commit a9ad1b85cc into main 2026-11-29 08:22:03 +00:00
This discussion has been locked. Commenting is limited to contributors.
No reviewers
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/trustno1-coder--VIctory-NVIDIA!972
No description provided.