Repository navigation
Conversation
catminou4
left a comment
There was a problem hiding this comment.
Static review only: this crate is Windows-only (D3D12/windows_sys/Win32) — nothing compiles or runs on macOS; source review of the diff.
f32_to_half fixes: NaN preserved as quiet f16 NaN with sign and upper payload bits (man >> 13, bit 9 set so a signalling NaN with payload below bit 13 never becomes infinity), overflow → infinity, and round-to-nearest-even implemented manually via lsb/sticky trick. The unit test covers quiet/signalling NaNs both signs plus normals. This is host-side bit manipulation — pure logic, but victory-gpu doesn't compile on macOS; the test runs on Windows only.
3dc6c12 to
5c781cf
Compare
|
NVIDIA run: RTX 3070 8 GB, driver 616.56, Windows 11, debug, at the PR head AI-assisted (Claude Code). Synthetic tests only. |
Code tree of fxceless/victory-fork 4e17478 (all rendering work by its author and the VIctory contributors) with, on top: - AMD fixes: skip of 39f0e9aeb156a61c, 32-lane programs per half wave and NaN/Inf filter, configurable texture upload queue, VIctory Marvisak#1599 - upstream VIctory Marvisak#334 (buffer-state tracking) and Marvisak#1271 (globally coherent glc UAVs) - fork PRs Marvisak#95, Marvisak#71, Marvisak#32, Marvisak#86; VIctory Marvisak#1696, Marvisak#1338, Marvisak#1291, Marvisak#1732 - DirectStorage page lists read at the title's submit (analysis by JappertjeV, klbf-lab#3) - offline pipeline pre-build that saves as it goes and skips driver-crashing pipelines - Series S plane composition, VICTORY_FFX_SIMPLE, scripted keys in release builds - docs/klbf/skip-amd.txt: AMD skip list used for our runs
|
Automated triage for the maintainers. Merge candidate. The On your reply: noted, and it merges cleanly with current CI: passing ( Generated by Claude Code |
(cherry picked from commit 63111de)
5c781cf to
1b97ccd
Compare
|
Rebased onto Checked on Windows 11, RTX 4070 SUPER, Rust 1.98.1 MSVC: both clippy configurations are clean, AI-assisted (Claude Code). |
|
Test report: RTX 5060 Ti (Blackwell), Windows 11 Pro 26200, driver 621.24. Branch at |
|
I reran the FP16 rectangle fallback from #2264 on The test-only If the extra regression is useful, it can be cherry-picked as-is. If it is folded into another commit, please retain |
Carry the rectangle regression from Marvisak#2264. Test both a NaN input and an infinity subtraction in the rectangle fallback while retaining the converter fix from Marvisak#1732.
|
@andrewpozdnakov7-jpg Thanks: cherry-picked as-is ( |
|
Code review and RTX 5090 + WARP verification at head
LGTM. |
Fixes #843.
This is AndyLatimer's fix from the issue (branch
fix/gpu-f32-to-half-nan-and-rne,63111de), cherry-picked unchanged ontomainwith the original author kept on the commit. It was posted as a fork branch while PRs were limited to collaborators. The only PR that carried it (#1069) was closed without being merged, so nothing open fixes #843 now.f32_to_half(crates/victory-gpu/src/primitive.rs, used forF16attributes in the rectangle-list expansion) had two IEEE-754 errors:0xff, so it fell intoexp >= 31and returned±0x7c00. It now returns a quiet half NaN that keeps the sign and the upper payload bits (0x7e00 | man >> 13), so a signalling NaN with a low payload stays a NaN.(man + 0x1000) >> 13rounded1.0 + 2^-11up to odd0x3c01. It now rounds to nearest even (man + 0x0fff + lsb), matching the subnormal branch just above it. The carry still stops at0x7c00(65520 rounds to infinity).The added test covers quiet and signalling NaNs of both signs, infinities, ties on both sides, the overflow boundary, and a round trip of every half bit pattern.
Checked on Windows 11 x64, Rust 1.98.1 MSVC,
mainffe310e+ this commit:cargo clippy --workspace --all-targets --locked -- -D warningsand the--all-featuresvariant: cleancargo test --workspace --locked: pass (victory-gpu: 51 passed, including the new test)cargo xtask policy: okIndependent checks are posted on #843: the new test fails on
main, and an exhaustive comparison over all 2^32 f32 inputs against Rust'sas f16found 0 mismatches on non-NaN inputs.AI-assisted (Claude Code): I reviewed the diff and reran the checks. The fix itself is AndyLatimer's (commit author Manuel Pérez).
🤖 Generated with Claude Code