Keep the confirmed FP32 mode for default paired programs when a list is set #429

Closed
Kal0s-design wants to merge 661 commits from upstream-pr/429 into main
Kal0s-design commented 2026-11-28 21:13:34 +00:00 (Migrated from github.com)

Imported from TaynanGT/Vice-Tay. Originally posted by Kal0s-design on 2026-11-28T21:13:34Z.


Fixes #426.

emit() confirms the guest float mode for the programs paired by default, so their ordered FP32 reductions take the paired form (paired_fp32.rs, None => paired_by_default_here()). That only happened while VICTORY_WAVE_PAIRS_ONLY was unset:

let by_default = std::env::var_os("VICTORY_WAVE_PAIRS_ONLY").is_none() && paired_by_default(c.input);

With a list that names default programs, which is what the #378 workaround does (the default list minus CS_GatherDiffusion), those programs lost the confirmation. The report shows 7 of 28 refused with "paired FP32 reduction requires a confirmed non-IEEE RNE/FTZ guest mode" and falling back to the unpaired form, and the dark rectangles on open water came back. docs/this-fork.md only asks for VICTORY_WAVE_PAIRS_FP32=non-ieee-rne-ftz for programs that are not on the default list.

Change

  • by_default is now paired_by_default(c.input) alone. A default program's MODE writes were checked whether or not a list names it, and VICTORY_WAVE_PAIRS_FP32 still overrides the confirmation either way.
  • The shader cache key gets a marker while VICTORY_WAVE_PAIRS_ONLY is set and non-empty. Translations cached under the same list before this change refused those programs the paired form, and the key already holds the list value but not the translator source. Runs without the variable keep their key, so nobody else translates again. That's the same pattern as VICTORY_PORT_CBV.
  • paired_by_default_hash split out of paired_by_default with a small test.

Checked

  • cargo clippy --workspace --all-targets --locked -- -D warnings: clean.
  • cargo test -p victory-shader --lib filtered to the paired/wave-pairs tests: 10 passed, and victory-gpu shader_cache tests: 4 passed (native Windows, NVIDIA card).
  • Not run in game here. The issue's own check (VICTORY_WAVE_PAIRS_FP32=non-ieee-rne-ftz added to the same list: 28/28 paired, water fixed) is the behaviour this makes the default for listed default programs.

AI-assisted: yes

🤖 Generated with Claude Code

<!-- greyfinch-sync:TaynanGT/Vice-Tay:issue:5544628898 --> Imported from [TaynanGT/Vice-Tay](https://github.com/TaynanGT/Vice-Tay/pull/429). Originally posted by [Kal0s-design](https://github.com/Kal0s-design) on 2026-11-28T21:13:34Z. --- Fixes #426. `emit()` confirms the guest float mode for the programs paired by default, so their ordered FP32 reductions take the paired form (`paired_fp32.rs`, `None => paired_by_default_here()`). That only happened while `VICTORY_WAVE_PAIRS_ONLY` was unset: ```rust let by_default = std::env::var_os("VICTORY_WAVE_PAIRS_ONLY").is_none() && paired_by_default(c.input); ``` With a list that names default programs, which is what the #378 workaround does (the default list minus `CS_GatherDiffusion`), those programs lost the confirmation. The report shows 7 of 28 refused with "paired FP32 reduction requires a confirmed non-IEEE RNE/FTZ guest mode" and falling back to the unpaired form, and the dark rectangles on open water came back. `docs/this-fork.md` only asks for `VICTORY_WAVE_PAIRS_FP32=non-ieee-rne-ftz` for programs that are not on the default list. ### Change - `by_default` is now `paired_by_default(c.input)` alone. A default program's MODE writes were checked whether or not a list names it, and `VICTORY_WAVE_PAIRS_FP32` still overrides the confirmation either way. - The shader cache key gets a marker while `VICTORY_WAVE_PAIRS_ONLY` is set and non-empty. Translations cached under the same list before this change refused those programs the paired form, and the key already holds the list value but not the translator source. Runs without the variable keep their key, so nobody else translates again. That's the same pattern as `VICTORY_PORT_CBV`. - `paired_by_default_hash` split out of `paired_by_default` with a small test. ### Checked - `cargo clippy --workspace --all-targets --locked -- -D warnings`: clean. - `cargo test -p victory-shader --lib` filtered to the paired/wave-pairs tests: 10 passed, and `victory-gpu` `shader_cache` tests: 4 passed (native Windows, NVIDIA card). - Not run in game here. The issue's own check (`VICTORY_WAVE_PAIRS_FP32=non-ieee-rne-ftz` added to the same list: 28/28 paired, water fixed) is the behaviour this makes the default for listed default programs. AI-assisted: yes 🤖 Generated with [Claude Code](https://claude.com/claude-code)
TaynanGT commented 2026-11-29 11:35:32 +00:00 (Migrated from github.com)

Imported from TaynanGT/Vice-Tay. Originally posted by TaynanGT on 2026-11-29T11:35:32Z.


Thanks for the focused fix and cache-key distinction. Please keep confirmation limited to the previously checked default programs, with an explicit override for other entries. The 28-program workaround in #426 is good evidence for the next matched in-game verification, not yet a test of this PR itself.

<!-- greyfinch-sync:TaynanGT/Vice-Tay:comment:7255216214 --> Imported from [TaynanGT/Vice-Tay](https://github.com/TaynanGT/Vice-Tay/pull/429#issuecomment-7255216214). Originally posted by [TaynanGT](https://github.com/TaynanGT) on 2026-11-29T11:35:32Z. --- Thanks for the focused fix and cache-key distinction. Please keep confirmation limited to the previously checked default programs, with an explicit override for other entries. The 28-program workaround in #426 is good evidence for the next matched in-game verification, not yet a test of this PR itself.
TaynanGT commented 2026-11-30 17:07:40 +00:00 (Migrated from github.com)

Imported from TaynanGT/Vice-Tay. Originally posted by TaynanGT on 2026-11-30T17:07:40Z.


main has moved to a new line of the code and everything is now named Vice-Tay, so this PR no longer applies as it is (details in #468). If you'd like this change in, please rebuild it on the current main and open a new PR; I'll review it there.

<!-- greyfinch-sync:TaynanGT/Vice-Tay:comment:7285761022 --> Imported from [TaynanGT/Vice-Tay](https://github.com/TaynanGT/Vice-Tay/pull/429#issuecomment-7285761022). Originally posted by [TaynanGT](https://github.com/TaynanGT) on 2026-11-30T17:07:40Z. --- `main` has moved to a new line of the code and everything is now named Vice-Tay, so this PR no longer applies as it is (details in #468). If you'd like this change in, please rebuild it on the current `main` and open a new PR; I'll review it there.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
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.

Reference
TaynanGT/Vice-Tay!429
No description provided.