Capture: preserve short words in tiny target logs #2817
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/2819"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-25T21:26:22Z.
The tiny target log groups each row into four-byte words. If the row ends in a shorter group, converting that slice directly to a four-byte array fails and the log prints zero. A 1x1 R8 or R16 target can therefore have nonzero bytes while its entire raw-value line shows zero.
Keep the existing hexadecimal and float descriptions for complete words. Print a short group as little-endian hex with two digits per byte, without including the row pitch padding in that group.
The same synthetic test checks one-, two-, and three-byte remainders, two separately padded rows, and an unchanged complete word. The base prints
0x0=0in place of0x3c00and0x0001on the two R16 rows. On the patch all three capture unit tests pass. No game data used. AI-assisted.Imported from Marvisak/VIctory. Originally posted by kotekompotek on 2026-11-25T21:51:35Z.
Review: COMMENTED
Good fix: the old try_into().unwrap_or_default() printed a short tail chunk zero-padded as a full f32 word, misleadingly. Width-aware hex for partial words preserves the distinction. Test covers both. LGTM.
Imported from Marvisak/VIctory. Originally posted by fuzeofficlal on 2026-11-25T21:41:00Z.
Verified
3bbcde9bon Windows 11 (RTX 5090 + WARP):cargo xtask policy: 184 files ok;cargo clippy --locked -p victory-gpu --all-targets -- -D warnings(default &--features diagnostics): 0 warnings.capture::tests: 3/3 passed on both RTX 5090 and WARP (includingtiny_capture_keeps_short_words_on_each_row).tiny_wordscleanly prints complete 4-byte chunks as{w:#x}={f32}and preserves trailing 1–3 byte slices in little-endian hex without zeroing them out. Cleangit merge-treeagainstorigin/main13f91ca.Imported from Marvisak/VIctory. Originally posted by Marvisak on 2026-11-26T02:21:19Z.
Automated triage for the maintainers.
A small diagnostics fix in
capture.rs. The tiny-target log converted a short trailing group (fewer than 4 bytes, for example a 1x1 R8 or R16 target) withtry_into().unwrap_or_default()and printed0. The newtiny_wordspads the group and prints it as hex, and complete words print as before. The unit test covers 1-, 2- and 3-byte remainders and per-row padding.CI: passing.
Generated by Claude Code
Imported from Marvisak/VIctory. Originally posted by Dukestar69 on 2026-11-26T03:48:52Z.
Review: APPROVED
Tested merged onto
origin/main(63bcca4) on Windows 11 x64:cargo test -p victory-gpu --features diagnostics --lib capture::tests: 6 passed, 0 failed (including newtiny_capture_keeps_short_words_on_each_row).cargo clippy -p victory-gpu --all-targets -- -D warnings: clean.cargo clippy -p victory-gpu --all-targets --features diagnostics -- -D warnings: clean.cargo xtask policy: 191 files ok.Synthetic tests only (no game files used). AI-assisted (Gemini 4 Neon).
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.