The NVIDIA fork built on this tree carries none of the wave64 work, so 8 compute pipelines are refused: a port, and what it measured #323

Open
opened 2026-11-26 16:48:49 +00:00 by github-bot · 3 comments
Owner

@⁠Razen114514 on GitHub · 2026-11-26 16:47 UTC · original

The NVIDIA fork built on this tree carries none of the wave64 work, so 8 compute pipelines are refused: a port, and what it measured

Posted here because trustno1-coder/VIctory-NVIDIA has issues disabled, and this
tree is its direct parent — its README says "A fork of avatarmanz/VIctory-7900XTX,
itself a fork of VIctory". Close it if it belongs in a different place.

The problem there specifically

On trustno1-coder/VIctory-NVIDIA at 033be27, eight compute programs that declare WaveSize(64) cannot get a host
pipeline on an NVIDIA card. The card reports WaveLaneCountMin = WaveLaneCountMax = 32,
so CreateComputePipelineState returns E_INVALIDARG (0x80070057) — eight times, on
an RTX 5060 8 GB:

02384a60fda6f2d0   2cc4c197ee29e291   2da4beb386509b77   369cbe906ea72764
5dc3b25986622949   6b82bc7d22016cb5   6f225b641c5b0708   926c46bab3b86bd6

Eight is a small number against what Marvisak/VIctory#2220 reports on other hosts
(60–70, and reboot0000-cmd archived 394), but the consequence here is the same
shape: their dispatches never run.

What already exists upstream — I did not invent this

Marvisak/VIctory#2220 tracks this, and by now it holds measurements from several
people, including whole-archive runs over the title's shader set and comparisons of
five candidate PRs. PiloteCode's #854 / #993 (fxceless/victory-fork) is the
paired form that ExoCalibra/victory-exo carries. Nereziel/victory#6 ports
Kelvaroq 0052 for the same purpose on another lineage.

This fork, trustno1-coder/VIctory-NVIDIA, carries none of them. That is the gap
I filled — not the technique, the integration.

What the patches do

Four commits, three files that matter:

File Change
crates/victory-gpu/src/shader_cache.rs puts VICTORY_WAVE_PAIRS in the cache key — this fork's key path enumerates env vars here, and does not go through emit/mod.rs::translation_fingerprint, so without this the switch has no effect on caching
crates/victory-shader/src/emit/lower.rs the paired lowering — per-lane control flow becomes wave-wide; each host thread runs console lanes n and n + 32; masks, permutes and reductions cover both halves
crates/victory-shader/src/emit/mod.rs tries the paired form last, after every existing fallback, and accepts only a result that reports WaveSize(32); a failed attempt falls back to the original result

The original retry order is untouched. Nothing that worked before changes.

Attribution — the paired code is PiloteCode's, not mine

Per function, against victory-exo-src/crates/victory-shader/src/emit/lower.rs and
float64.rs:

Function exo this patch similarity what it is
with_paired_lanes 67 67 100 % copied
both 156 156 100 % copied
put_lanes 167 167 100 % copied
join_halves 607 607 100 % copied
half_tree 596 596 100 % copied
join_half_sums 266 266 100 % copied
lane_scalars 611 611 100 % copied
block_phis 494 494 100 % copied
paired_cross 2132 2132 100 % copied
paired_shape 1557 1456 96.6 % near copy
swap_lanes 702 714 97.2 % near copy
paired_section_inst 651 721 91.4 % adapted
paired_inst 1165 1276 83.9 % adapted
paired_sum64 591 1115 32.2 % rewritten

Origin: #854 (paired wave64) and #993 (Wave32 round 2), both by PiloteCode in
fxceless/victory-fork, integrated into ExoCalibra/victory-exo at c2e3c8b.
Correct the credit if any part belongs elsewhere.

What is genuinely new is the integration, because this fork has none of exo's
float64.rs, guarded.rs, forms.rs or link.rs:

  • exo's paired_sum64 lives in float64.rs and has a Float64 context. This fork
    has no such module, so it was rewritten inside lower.rs — hence 32 % similarity.
    Without it the second round of refusals reports
    a paired f64 wave reduction is not supported.
  • paired_inst and paired_section_inst needed adapting to this fork's own
    wave_base / guard / write_placed / lane_index / edge handling, and its
    permlane, DPP and cube-LOD paths had to stay untouched.

What it measured — RTX 5060 8 GB, 32 GB RAM, Windows 11

Quality profile (VICTORY_RELAY=1, VICTORY_CARD_STEPS=0, VICTORY_TEXTURE_NO_WAIT=0),
--console series-s, half render scale.

before after
host pipeline refused 8 0
dropped, 6000+ draws/frame 1781 556 – 613
copies, per frame 94 – 113 MB 51 – 64 MB
copying back, per frame 16 – 26 MB 11 – 14 MB
frame time, 4600 draws (open water) — 99.5 ms (10 fps)
frame time, 6000+ draws (dense trees) 183 ms 175 – 201 ms
indirect dropped, 6000+ draws 1310 1147 – 1780

Two rounds were needed: the first fixed six of the eight and left 5dc3b25986622949,
6f225b641c5b0708 (and later 926c46bab3b86bd6) failing on the f64 reduction.

cargo test -p victory-gpu: 333 passed, 0 failed, 34 ignored, same as the parent.

What it does not fix

The 6000+ draw cliff is unchanged. 175–201 ms before and after, and the
indirect-drop count is the same. The five dropped signatures are byte-for-byte
identical before and after:

stride=12 args=[[10, 0, 2356504239, 32767]]
stride=12 args=[[105, 0, 60000, 0]]
stride=12 args=[[2, 9, 0, 0]]
stride=16 args=[[0, 32767, 8, 0]]
stride=20 args=[[1, 32767, 2306893988, 32767]]

So the refused WaveSize(64) programs are not what refuses those. The likely guard is
in draw.rs::execute_indirect:

if crate::pipeline::is_builder(self.pipeline as This) && !crate::pipeline::builder_runs() {
    return false;
}

— i.e. structure-builder dispatches, refused because VICTORY_BVH_MISS=1 keeps the
builder off. Refusing them is correct with ray tracing disabled; the failed path is
just not free.

For a 6089 draw / 201 ms frame the measured budget covers only 93 ms (preparing 40.1

  • GPU 41.5 + copying back 11.5). The rest is not hidden work: the profiler puts the
    game thread in Present for 148–172 ms. That is submit-pipeline drain, and it is
    where the next fix belongs.

Two configuration findings

  1. VICTORY_RELAY=2 corrupts faces on its own. avatarmanz#13 documents the pair
    "RELAY=2 and CARD_STEPS>0". On Windows/NVIDIA I tried RELAY=2 with
    CARD_STEPS=0 and TEXTURE_NO_WAIT=0: the relay wait halved (41.5 → 22.7 ms) but
    individual characters came back with corrupted, coloured faces. So on this platform
    the guard is RELAY=2 itself. That may or may not generalise to the Linux/AMD
    report, which is why I am noting it as a data point, not a correction.
  2. VICTORY_TEXTURE_NO_WAIT=0 fixes black faces and is faster. The speed set ships
    =1, and with it faces and skin are pure black. With =0 they render correctly and
    the median frame went from 11 to 13 fps on the same scene — the opposite direction
    from what moving a wait to the slower setting suggests.

The configuration these numbers came from

--console series-s plus 27 variables: this fork's scripts/play-nvidia.ps1 speed
set with four changes — TEXTURE_NO_WAIT=0, RELAY=1, CARD_STEPS=0 (the Quality
block, all three; without any one of them faces or bodies break) and
PIPELINE_WAIT_MS=150 (that script's default 10000 cost multi-second freezes here:
p99 1472 ms → 236 ms), plus VICTORY_AMBIENT=constant:2.0 (the estimate form finds
no light on this card and the world renders black).

VICTORY_CARD_BUFFERS_MB is deliberately absent: on 8 GB the title's budget is
already at 5.3 GB of 6.7 GB with 3748 textures waiting, and reserving more made the
driver lower the system budget instead.

VICTORY_THIN_THREADS=6 was tried against the default 8 and was worse at every draw
count (3000–3999: 96.5 → 113.5 ms; 5000–5999: 108.7 → 114.0 ms).

Offering

I can send the four patches as a branch or a PR if you want them. They apply cleanly
on 033be27 with git am, and the resulting shader_cache.rs, lower.rs and
emit/mod.rs are byte-identical to the tree these numbers came from. I checked that
by applying them to a fresh worktree and diffing. They carry nothing else — no test
scripts, no unrelated commits.

How this was produced

Analysis, the port and every measurement were done with AI assistance:
DeepSeek-V4.1-Flash, as the DSH agent (measurement, diagnosis, upstream research,
driving the run) and as the Codex CLI (the lower.rs port, one file at a time, each
compiled and committed, then the f64 reduction). Every number came from running the
build on the machine described. Where a sample is small — the 6000+ bucket is 2 to 7
frames — the text says so instead of rounding it into a claim.

**@⁠Razen114514** on GitHub · 2026-11-26 16:47 UTC · [original](https://github.com/avatarmanz/VIctory-7900XTX/issues/323) # The NVIDIA fork built on this tree carries none of the wave64 work, so 8 compute pipelines are refused: a port, and what it measured **Posted here because `trustno1-coder/VIctory-NVIDIA` has issues disabled**, and this tree is its direct parent — its README says "A fork of avatarmanz/VIctory-7900XTX, itself a fork of VIctory". Close it if it belongs in a different place. ## The problem there specifically On `trustno1-coder/VIctory-NVIDIA` at `033be27`, eight compute programs that declare `WaveSize(64)` cannot get a host pipeline on an NVIDIA card. The card reports `WaveLaneCountMin = WaveLaneCountMax = 32`, so `CreateComputePipelineState` returns `E_INVALIDARG (0x80070057)` — eight times, on an RTX 5060 8 GB: ``` 02384a60fda6f2d0 2cc4c197ee29e291 2da4beb386509b77 369cbe906ea72764 5dc3b25986622949 6b82bc7d22016cb5 6f225b641c5b0708 926c46bab3b86bd6 ``` Eight is a small number against what `Marvisak/VIctory#2220` reports on other hosts (60–70, and `reboot0000-cmd` archived 394), but the consequence here is the same shape: their dispatches never run. ## What already exists upstream — I did not invent this `Marvisak/VIctory#2220` tracks this, and by now it holds measurements from several people, including whole-archive runs over the title's shader set and comparisons of five candidate PRs. `PiloteCode`'s **#854 / #993** (`fxceless/victory-fork`) is the paired form that `ExoCalibra/victory-exo` carries. `Nereziel/victory#6` ports Kelvaroq 0052 for the same purpose on another lineage. **This fork, `trustno1-coder/VIctory-NVIDIA`, carries none of them.** That is the gap I filled — not the technique, the integration. ## What the patches do Four commits, three files that matter: | File | Change | | --- | --- | | `crates/victory-gpu/src/shader_cache.rs` | puts `VICTORY_WAVE_PAIRS` in the cache key — this fork's key path enumerates env vars here, and does not go through `emit/mod.rs::translation_fingerprint`, so without this the switch has no effect on caching | | `crates/victory-shader/src/emit/lower.rs` | the paired lowering — per-lane control flow becomes wave-wide; each host thread runs console lanes `n` and `n + 32`; masks, permutes and reductions cover both halves | | `crates/victory-shader/src/emit/mod.rs` | tries the paired form **last**, after every existing fallback, and accepts only a result that reports `WaveSize(32)`; a failed attempt falls back to the original result | The original retry order is untouched. Nothing that worked before changes. ## Attribution — the paired code is PiloteCode's, not mine Per function, against `victory-exo-src/crates/victory-shader/src/emit/lower.rs` and `float64.rs`: | Function | exo | this patch | similarity | what it is | | --- | ---: | ---: | ---: | --- | | `with_paired_lanes` | 67 | 67 | 100 % | copied | | `both` | 156 | 156 | 100 % | copied | | `put_lanes` | 167 | 167 | 100 % | copied | | `join_halves` | 607 | 607 | 100 % | copied | | `half_tree` | 596 | 596 | 100 % | copied | | `join_half_sums` | 266 | 266 | 100 % | copied | | `lane_scalars` | 611 | 611 | 100 % | copied | | `block_phis` | 494 | 494 | 100 % | copied | | `paired_cross` | 2132 | 2132 | 100 % | copied | | `paired_shape` | 1557 | 1456 | 96.6 % | near copy | | `swap_lanes` | 702 | 714 | 97.2 % | near copy | | `paired_section_inst` | 651 | 721 | 91.4 % | adapted | | `paired_inst` | 1165 | 1276 | 83.9 % | adapted | | **`paired_sum64`** | 591 | **1115** | **32.2 %** | **rewritten** | Origin: **#854 (paired wave64) and #993 (Wave32 round 2), both by `PiloteCode`** in `fxceless/victory-fork`, integrated into `ExoCalibra/victory-exo` at `c2e3c8b`. Correct the credit if any part belongs elsewhere. What is genuinely new is the integration, because this fork has none of exo's `float64.rs`, `guarded.rs`, `forms.rs` or `link.rs`: - exo's `paired_sum64` lives in `float64.rs` and has a `Float64` context. This fork has no such module, so it was rewritten inside `lower.rs` — hence 32 % similarity. Without it the second round of refusals reports `a paired f64 wave reduction is not supported`. - `paired_inst` and `paired_section_inst` needed adapting to this fork's own `wave_base` / `guard` / `write_placed` / `lane_index` / `edge` handling, and its permlane, DPP and cube-LOD paths had to stay untouched. ## What it measured — RTX 5060 8 GB, 32 GB RAM, Windows 11 Quality profile (`VICTORY_RELAY=1`, `VICTORY_CARD_STEPS=0`, `VICTORY_TEXTURE_NO_WAIT=0`), `--console series-s`, half render scale. | | before | after | | --- | ---: | ---: | | `host pipeline refused` | **8** | **0** | | `dropped`, 6000+ draws/frame | 1781 | 556 – 613 | | `copies`, per frame | 94 – 113 MB | 51 – 64 MB | | `copying back`, per frame | 16 – 26 MB | 11 – 14 MB | | frame time, 4600 draws (open water) | — | 99.5 ms (10 fps) | | frame time, 6000+ draws (dense trees) | 183 ms | **175 – 201 ms** | | `indirect` dropped, 6000+ draws | 1310 | **1147 – 1780** | Two rounds were needed: the first fixed six of the eight and left `5dc3b25986622949`, `6f225b641c5b0708` (and later `926c46bab3b86bd6`) failing on the f64 reduction. `cargo test -p victory-gpu`: **333 passed, 0 failed, 34 ignored**, same as the parent. ## What it does not fix **The 6000+ draw cliff is unchanged.** 175–201 ms before and after, and the indirect-drop count is the same. The five dropped signatures are byte-for-byte identical before and after: ``` stride=12 args=[[10, 0, 2356504239, 32767]] stride=12 args=[[105, 0, 60000, 0]] stride=12 args=[[2, 9, 0, 0]] stride=16 args=[[0, 32767, 8, 0]] stride=20 args=[[1, 32767, 2306893988, 32767]] ``` So the refused `WaveSize(64)` programs are not what refuses those. The likely guard is in `draw.rs::execute_indirect`: ```rust if crate::pipeline::is_builder(self.pipeline as This) && !crate::pipeline::builder_runs() { return false; } ``` — i.e. structure-builder dispatches, refused because `VICTORY_BVH_MISS=1` keeps the builder off. Refusing them is correct with ray tracing disabled; the failed path is just not free. For a 6089 draw / 201 ms frame the measured budget covers only 93 ms (preparing 40.1 + GPU 41.5 + copying back 11.5). The rest is not hidden work: the profiler puts the game thread in `Present` for 148–172 ms. That is submit-pipeline drain, and it is where the next fix belongs. ## Two configuration findings 1. **`VICTORY_RELAY=2` corrupts faces on its own.** `avatarmanz#13` documents the pair "`RELAY=2` and `CARD_STEPS>0`". On Windows/NVIDIA I tried `RELAY=2` with `CARD_STEPS=0` and `TEXTURE_NO_WAIT=0`: the relay wait halved (41.5 → 22.7 ms) but individual characters came back with corrupted, coloured faces. So on this platform the guard is `RELAY=2` itself. That may or may not generalise to the Linux/AMD report, which is why I am noting it as a data point, not a correction. 2. **`VICTORY_TEXTURE_NO_WAIT=0` fixes black faces and is faster.** The speed set ships `=1`, and with it faces and skin are pure black. With `=0` they render correctly and the median frame went from 11 to 13 fps on the same scene — the opposite direction from what moving a wait to the slower setting suggests. ## The configuration these numbers came from `--console series-s` plus 27 variables: this fork's `scripts/play-nvidia.ps1` speed set with four changes — `TEXTURE_NO_WAIT=0`, `RELAY=1`, `CARD_STEPS=0` (the Quality block, all three; without any one of them faces or bodies break) and `PIPELINE_WAIT_MS=150` (that script's default 10000 cost multi-second freezes here: p99 1472 ms → 236 ms), plus `VICTORY_AMBIENT=constant:2.0` (the estimate form finds no light on this card and the world renders black). `VICTORY_CARD_BUFFERS_MB` is deliberately absent: on 8 GB the title's budget is already at 5.3 GB of 6.7 GB with 3748 textures waiting, and reserving more made the driver lower the system budget instead. `VICTORY_THIN_THREADS=6` was tried against the default 8 and was worse at every draw count (3000–3999: 96.5 → 113.5 ms; 5000–5999: 108.7 → 114.0 ms). ## Offering I can send the four patches as a branch or a PR if you want them. They apply cleanly on `033be27` with `git am`, and the resulting `shader_cache.rs`, `lower.rs` and `emit/mod.rs` are byte-identical to the tree these numbers came from. I checked that by applying them to a fresh worktree and diffing. They carry nothing else — no test scripts, no unrelated commits. ## How this was produced Analysis, the port and every measurement were done with AI assistance: **DeepSeek-V4.1-Flash**, as the DSH agent (measurement, diagnosis, upstream research, driving the run) and as the Codex CLI (the `lower.rs` port, one file at a time, each compiled and committed, then the f64 reduction). Every number came from running the build on the machine described. Where a sample is small — the 6000+ bucket is 2 to 7 frames — the text says so instead of rounding it into a claim.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 16:48:49 +00:00
Author
Owner

@⁠Razen114514 on GitHub · 2026-11-26 17:26 UTC · original

Update: the paired form is not safe to play with on this title — black rectangles on water

Follow-up after living with the port for a while. This changes the recommendation in
the report above, so it goes first.

The A/B

Same tree, same build, same scene, only VICTORY_WAVE_PAIRS changed:

VICTORY_WAVE_PAIRS host pipeline refused Sea surface Characters in crowds
0 (off) 8 clean collapse into polygon blobs
1 (default) 0 large black rectangles over the water render correctly

So the switch trades one visible defect for another. Neither setting is correct.

What that means

At least one of the eight programs that only the paired form can build produces wrong
output. The failure is not a refusal and not a crash — the pipeline is created, it
runs, and what it writes is wrong. On water that shows up as large black rectangles;
with the program absent entirely (paired off) those draws are dropped instead, which
corrupts the characters in crowded scenes.

The eight hashes involved:

02384a60fda6f2d0   2cc4c197ee29e291   2da4beb386509b77   369cbe906ea72764
5dc3b25986622949   6b82bc7d22016cb5   6f225b641c5b0708   926c46bab3b86bd6

I have not yet bisected which one it is. VICTORY_SKIP_PIPELINES is a diagnostics-only
switch in this tree, so the bisect needs a diagnostics build and one run per hash —
that is the next step, not something I am claiming to have done.

A second finding: #2143 makes it much worse

Marvisak/VIctory#2143 (merged as e04c078, "a program's constant table starts after
its instructions") is not the cause, but on top of the paired form it multiplies
the rectangles: the sea goes from a few to many. Reverting #2143 alone brings it
back to "a few", so I am reporting the two separately rather than blaming either.

I could not measure a video-memory saving from #2143 either. On this 8 GB card the
pool sat at 5.7 GB of 6.7 GB with 3.3–3.7 k textures still waiting, against 5.3 GB
of 6.7 GB before it. That is within noise on an unsettled sample, and the sample was
unsettled because changing the constant-table layout invalidates the whole shader
cache. It may well be a real win on a card with headroom; I am not claiming it here.

The correction to my own earlier numbers

In the report above I wrote "indirect draws dropped at 6000+: 1310 → 1147–1780"
and framed the port as a net improvement. That framing was too generous for
playability. What is solidly true:

  • the eight refusals do become zero, and that is reproducible;
  • dropped, copies and copying back all fall measurably;
  • but the water defect makes the paired form unusable for actually playing in its
    current state, so those gains are not currently reachable in a session.

If you would rather keep this issue to the mechanism, the practical recommendation for
players on this fork today is VICTORY_WAVE_PAIRS=0 and a smaller crowd density,
not the paired form.

**@⁠Razen114514** on GitHub · 2026-11-26 17:26 UTC · [original](https://github.com/avatarmanz/VIctory-7900XTX/issues/323#issuecomment-7199025640) ## Update: the paired form is not safe to play with on this title — black rectangles on water Follow-up after living with the port for a while. This changes the recommendation in the report above, so it goes first. ### The A/B Same tree, same build, same scene, only `VICTORY_WAVE_PAIRS` changed: | `VICTORY_WAVE_PAIRS` | `host pipeline refused` | Sea surface | Characters in crowds | | --- | ---: | --- | --- | | `0` (off) | 8 | **clean** | **collapse into polygon blobs** | | `1` (default) | **0** | **large black rectangles over the water** | render correctly | So the switch trades one visible defect for another. Neither setting is correct. ### What that means At least one of the eight programs that only the paired form can build produces wrong output. The failure is not a refusal and not a crash — the pipeline is created, it runs, and what it writes is wrong. On water that shows up as large black rectangles; with the program absent entirely (paired off) those draws are dropped instead, which corrupts the characters in crowded scenes. The eight hashes involved: ``` 02384a60fda6f2d0 2cc4c197ee29e291 2da4beb386509b77 369cbe906ea72764 5dc3b25986622949 6b82bc7d22016cb5 6f225b641c5b0708 926c46bab3b86bd6 ``` I have not yet bisected which one it is. `VICTORY_SKIP_PIPELINES` is a diagnostics-only switch in this tree, so the bisect needs a diagnostics build and one run per hash — that is the next step, not something I am claiming to have done. ### A second finding: #2143 makes it much worse `Marvisak/VIctory#2143` (merged as `e04c078`, "a program's constant table starts after its instructions") is **not** the cause, but on top of the paired form it multiplies the rectangles: the sea goes from a few to many. Reverting `#2143` alone brings it back to "a few", so I am reporting the two separately rather than blaming either. I could not measure a video-memory saving from `#2143` either. On this 8 GB card the pool sat at 5.7 GB of 6.7 GB with 3.3–3.7 k textures still waiting, against 5.3 GB of 6.7 GB before it. That is within noise on an unsettled sample, and the sample was unsettled because changing the constant-table layout invalidates the whole shader cache. It may well be a real win on a card with headroom; I am not claiming it here. ### The correction to my own earlier numbers In the report above I wrote "`indirect` draws dropped at 6000+: 1310 → **1147–1780**" and framed the port as a net improvement. That framing was too generous for playability. What is solidly true: - the eight refusals do become zero, and that is reproducible; - `dropped`, `copies` and `copying back` all fall measurably; - but the water defect makes the paired form **unusable for actually playing** in its current state, so those gains are not currently reachable in a session. If you would rather keep this issue to the mechanism, the practical recommendation for players on this fork today is `VICTORY_WAVE_PAIRS=0` and a smaller crowd density, not the paired form.
Author
Owner

@⁠Razen114514 on GitHub · 2026-11-26 18:27 UTC · original

Resolved on my machine: gate the paired f64 reduction, keep the rest of the paired form

The bisect finished, and the answer is narrower than "the paired form is wrong".

The three programs that matter

victory translate --validate --pipelines --list --only over the game folder names them:

5dc3b25986622949   water_shading:CS_TransmissionVolumetrics_Tiled
6f225b641c5b0708   water_shading:CS_TransmissionVolumetrics_Tiled_LocalLights
926c46bab3b86bd6   water_shading:CS_TransmissionVolumetricsSubmerged

All three reach the paired form's f64 reduction (Shape::ActiveF64 ->
paired_sum64). The first two are the ones that actually change behaviour when that
reduction is refused; the third builds either way.

The fix, such as it is

Rather than skipping three hashes, I gated the f64 reduction itself off by default:

// lower.rs, paired_sum64
// Off unless asked for (`VICTORY_WAVE_PAIRS_F64=1`): the three
// water_shading:CS_TransmissionVolumetrics* programs are the only ones that
// reach this, and with it on they translate, validate, build, and draw large
// black rectangles over the water. Refusing them instead leaves the sea clean.
if std::env::var_os("VICTORY_WAVE_PAIRS_F64").is_none_or(|v| v != "1") {
    return Err("a paired f64 wave reduction, off until the picture is right");
}

With that, a release build reports exactly two refusals:

host pipeline refused  shaders=[compute 5dc3b25986622949]
host pipeline refused  shaders=[compute 6f225b641c5b0708]

and the result is: sea clean, characters correct, 8.7–9 fps at 4 035 draws. The
other five paired programs (vfx_triangleClip, sr_tracing, alphaResolve,
GpuParticleUpdate) still build and run, which is what keeps the characters from
collapsing — that was the defect with VICTORY_WAVE_PAIRS=0, where all eight are
refused.

So the trade is now three-way, and only the middle setting is usable:

setting refusals sea characters
VICTORY_WAVE_PAIRS=0 8 clean polygon blobs
VICTORY_WAVE_PAIRS=1 (as ported) 0 black rectangles correct
=1, f64 reduction off 2 clean correct

One thing to watch out for when reproducing this

The pipeline library is keyed such that a stale host-pipelines.bin hides the change.
After editing the translator I had to move both cache/shaders and
cache/pipelines/host-pipelines.bin aside before the two refusals appeared in a run;
until then the old pipelines were reused and the log said zero refusals while the
water still drew wrong. Worth knowing before someone concludes a fix "did nothing".

What this implies for the candidate-PR comparison in #2220

The report above argued that a refusal count of zero is not sufficient evidence. This
is the concrete case: #854/#993 with the f64 reduction reaches zero refusals and
draws wrong water.
Two refusals here are the correct state, not a regression. If the
comparison table in #2220 is read as "fewer refusals is better", this fork's best
configuration looks worse than its worst one.

The honest statement of what I now believe: the paired form is right for the
vfx_triangleClip / sr_tracing / alphaResolve / GpuParticleUpdate programs, and
wrong for the volumetrics reductions. I have not established why the f64 sum is
wrong — only that refusing it fixes the picture. Somebody with more time than me
should compare paired_sum64's reduction order against what GFX10 actually does for
these three, which is where I would look next.

**@⁠Razen114514** on GitHub · 2026-11-26 18:27 UTC · [original](https://github.com/avatarmanz/VIctory-7900XTX/issues/323#issuecomment-7200491291) ## Resolved on my machine: gate the paired f64 reduction, keep the rest of the paired form The bisect finished, and the answer is narrower than "the paired form is wrong". ### The three programs that matter `victory translate --validate --pipelines --list --only` over the game folder names them: ``` 5dc3b25986622949 water_shading:CS_TransmissionVolumetrics_Tiled 6f225b641c5b0708 water_shading:CS_TransmissionVolumetrics_Tiled_LocalLights 926c46bab3b86bd6 water_shading:CS_TransmissionVolumetricsSubmerged ``` All three reach the paired form's f64 reduction (`Shape::ActiveF64` -> `paired_sum64`). The first two are the ones that actually change behaviour when that reduction is refused; the third builds either way. ### The fix, such as it is Rather than skipping three hashes, I gated the f64 reduction itself off by default: ```rust // lower.rs, paired_sum64 // Off unless asked for (`VICTORY_WAVE_PAIRS_F64=1`): the three // water_shading:CS_TransmissionVolumetrics* programs are the only ones that // reach this, and with it on they translate, validate, build, and draw large // black rectangles over the water. Refusing them instead leaves the sea clean. if std::env::var_os("VICTORY_WAVE_PAIRS_F64").is_none_or(|v| v != "1") { return Err("a paired f64 wave reduction, off until the picture is right"); } ``` With that, a release build reports exactly two refusals: ``` host pipeline refused shaders=[compute 5dc3b25986622949] host pipeline refused shaders=[compute 6f225b641c5b0708] ``` and the result is: **sea clean, characters correct, 8.7–9 fps at 4 035 draws**. The other five paired programs (`vfx_triangleClip`, `sr_tracing`, `alphaResolve`, `GpuParticleUpdate`) still build and run, which is what keeps the characters from collapsing — that was the defect with `VICTORY_WAVE_PAIRS=0`, where all eight are refused. So the trade is now three-way, and only the middle setting is usable: | setting | refusals | sea | characters | | --- | ---: | --- | --- | | `VICTORY_WAVE_PAIRS=0` | 8 | clean | polygon blobs | | `VICTORY_WAVE_PAIRS=1` (as ported) | 0 | **black rectangles** | correct | | **`=1`, f64 reduction off** | **2** | **clean** | **correct** | ### One thing to watch out for when reproducing this The pipeline library is keyed such that a stale `host-pipelines.bin` hides the change. After editing the translator I had to move both `cache/shaders` and `cache/pipelines/host-pipelines.bin` aside before the two refusals appeared in a run; until then the old pipelines were reused and the log said zero refusals while the water still drew wrong. Worth knowing before someone concludes a fix "did nothing". ### What this implies for the candidate-PR comparison in #2220 The report above argued that a refusal count of zero is not sufficient evidence. This is the concrete case: **#854/#993 with the f64 reduction reaches zero refusals and draws wrong water.** Two refusals here are the correct state, not a regression. If the comparison table in #2220 is read as "fewer refusals is better", this fork's best configuration looks worse than its worst one. The honest statement of what I now believe: the paired form is right for the `vfx_triangleClip` / `sr_tracing` / `alphaResolve` / `GpuParticleUpdate` programs, and wrong for the volumetrics reductions. I have not established *why* the f64 sum is wrong — only that refusing it fixes the picture. Somebody with more time than me should compare `paired_sum64`'s reduction order against what GFX10 actually does for these three, which is where I would look next.
Author
Owner

@⁠Razen114514 on GitHub · 2026-11-26 19:40 UTC · original

Correction: the VICTORY_AMBIENT note in the report is about this fork, not about the card

One line in the report above overreaches and I want it right before anyone acts on it.

I wrote, in "The configuration these numbers came from":

plus VICTORY_AMBIENT=constant:2.0 (the estimate form finds no light on this card and the world renders black)

The measurement is real for trustno1-coder/VIctory-NVIDIA at 033be27: with
VICTORY_AMBIENT=0.8 (the bare estimate form) the world came out effectively black on
this machine, and switching to the constant: form lit it.

But "on this card" is the wrong scope, and I have since measured a tree where it does
not hold. On DoubleGhosty/cool_fox at 3277b15, whose launcher ships
VICTORY_AMBIENT=constant:0.8 (not 0.8), the same RTX 5060 renders daylight
correctly. There, dropping the constant: prefix gives a dark world rather than a
black one — 6.3 % of the frame above 60/255 against 58.2 % with the prefix — so the
estimate form is not "no light", it is "much less light", and how much less depends on
the tree's ambient implementation, not on the GPU.

Two further things I got wrong while chasing this, in case they save someone a night:

  1. constant: does not blacken the sun. I concluded that after trying
    VICTORY_AMBIENT=constant:2.0, which blew the exposure out so that the sun disc and
    its reflection on the water read as black against everything else. The shipped value
    is constant:0.8. The form was fine; my number was not.
  2. A run with only part of a launcher's settings is not that launcher's default. I
    first reproduced this fork's preset from the first fourteen lines of
    Play-VIctory.cmd and missed PORT_CBV, PORT_CONSTANTS, TEXTURE_GUARD,
    LEVELS_ON_DEMAND, SHOW_AFTER, THIN, JOIN_PARTS, UPLOAD_AHEAD,
    CARD_BUFFERS_MIN_KB and the correct AMBIENT value — eleven settings out of
    twenty-five. Every conclusion I drew from those runs about lighting and speed was
    measured against something no upstream author ships. The launcher file is the
    tested configuration.

Nothing else in the report changes: the eight refusals, the two that remain with the f64
reduction gated off, the water_shading programme names, the stale-pipeline-library
trap, and the argument that a refusal count of zero is not sufficient evidence all stand
on their own measurements.

**@⁠Razen114514** on GitHub · 2026-11-26 19:40 UTC · [original](https://github.com/avatarmanz/VIctory-7900XTX/issues/323#issuecomment-7201841365) ## Correction: the `VICTORY_AMBIENT` note in the report is about this fork, not about the card One line in the report above overreaches and I want it right before anyone acts on it. I wrote, in "The configuration these numbers came from": > plus `VICTORY_AMBIENT=constant:2.0` (the estimate form finds no light on this card and the world renders black) The measurement is real **for `trustno1-coder/VIctory-NVIDIA` at `033be27`**: with `VICTORY_AMBIENT=0.8` (the bare estimate form) the world came out effectively black on this machine, and switching to the `constant:` form lit it. But "on this card" is the wrong scope, and I have since measured a tree where it does not hold. On `DoubleGhosty/cool_fox` at `3277b15`, whose launcher ships `VICTORY_AMBIENT=constant:0.8` (not `0.8`), the same RTX 5060 renders daylight correctly. There, dropping the `constant:` prefix gives a *dark* world rather than a black one — 6.3 % of the frame above 60/255 against 58.2 % with the prefix — so the estimate form is not "no light", it is "much less light", and how much less depends on the tree's ambient implementation, not on the GPU. Two further things I got wrong while chasing this, in case they save someone a night: 1. **`constant:` does not blacken the sun.** I concluded that after trying `VICTORY_AMBIENT=constant:2.0`, which blew the exposure out so that the sun disc and its reflection on the water read as black against everything else. The shipped value is `constant:0.8`. The form was fine; my number was not. 2. **A run with only part of a launcher's settings is not that launcher's default.** I first reproduced this fork's preset from the first fourteen lines of `Play-VIctory.cmd` and missed `PORT_CBV`, `PORT_CONSTANTS`, `TEXTURE_GUARD`, `LEVELS_ON_DEMAND`, `SHOW_AFTER`, `THIN`, `JOIN_PARTS`, `UPLOAD_AHEAD`, `CARD_BUFFERS_MIN_KB` and the correct `AMBIENT` value — eleven settings out of twenty-five. Every conclusion I drew from those runs about lighting and speed was measured against something no upstream author ships. The launcher file *is* the tested configuration. Nothing else in the report changes: the eight refusals, the two that remain with the f64 reduction gated off, the `water_shading` programme names, the stale-pipeline-library trap, and the argument that a refusal count of zero is not sufficient evidence all stand on their own measurements.
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/avatarmanz--VIctory-7900XTX#323
No description provided.