Game tests: cover CityHash64 length and block boundaries #2658
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory!2658
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-2658"
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?
@XeNS1 on GitHub · 2026-11-25 17:41 UTC · original
XeNS1:codex/cityhash-boundary-vectors-20261125→main· +82 −0 · 1 files · 1 commits · openThe current CityHash64 regression checks 13 arithmetic-pattern inputs. It misses several length dispatch boundaries and exact 64-byte loop boundaries, so off-by-one changes there can pass the existing test. These hashes identify the compact pipeline states.
Add two tests with 42 independent reference cases: 36 generated inputs at short-input, 64-byte block and longer-loop boundaries, plus zero/0xff inputs at the compact 16/24/68-byte state sizes. Run each case at offsets 0 through 7 with unrelated bytes surrounding the slice (336 comparisons). All expected values come from Google's C++ CityHash64 at
f5dc541, compiled locally with g++ -O2; that reference build also passes its upstream city-test.cc suite.Validation on Linux x86-64 / Rust 1.100.0:
cargo test -p victory-game --locked --offline: 17 tests pass.cargo clippy -p victory-game --all-targets --all-features --locked --offline -- -D warnings: passes.git diff --check: pass.Test coverage only; production code is unchanged and no existing algorithm mismatch was found. Full Windows CI on pinned Rust 1.98.1 also passed: workspace Clippy, all-features Clippy, and workspace tests (run). Fixtures are generated in source, with no game files accessed or included and no new dependency.
Coordination claim. AI-assisted: OpenAI Codex.
@kotekompotek on GitHub · 2026-11-25 17:54 UTC · original
Reviewed: expected values pinned to Google's city.cc at a named commit, covering every algorithm boundary (0–4, 5–8, 9–16, 17–32, 33–64, 65–96/128, block multiples, >4 KiB). Deterministic input generator, no game data. Test-only; CI green.
@Marvisak on GitHub · 2026-11-25 22:21 UTC · original
Automated triage for the maintainers.
Merge candidate (test only). Adds two tests to
crates/victory-game/src/cityhash.rsthat check CityHash64 at every length-dispatch boundary (0-4, 8/9, 16/17, 32/33, 64/65), at exact 64-byte block multiples and longer inputs, and for all-zero/all-0xff inputs at the 16/24/68-byte state sizes. Each case also runs at offsets 0-7 inside unrelated bytes. Expected values come from Google's publiccity.ccat a pinned commit; the inputs are generated in the test, and the empty-input value matches CityHash'sk2constant, which I checked. Production code is unchanged. It merges cleanly; CIcheck: passing.Generated by Claude Code
@fuzeofficlal on GitHub · 2026-11-26 00:56 UTC · original
Code review and Windows 11 verification at head
119addfe9eaamerged cleanly ontomain(63bcca43c6a0):crates/victory-game/src/cityhash.rs):city64dispatch threshold (0,1..3,4..7,8..16,17..32,33..64,65..68, and multi-64B block boundaries up to4097), plus unaligned subslice offsets (0..8) with0xa5/0x5aguard bytes.cargo xtask policy:191 files ok;cargo clippy --locked -p victory-game --tests -- -D warnings: 0 warningscargo test --locked -p victory-game: 17/17 passed.LGTM.
@futurepro62 on GitHub · 2026-11-26 01:16 UTC · original
NVIDIA full-suite run, to go with the reports above by fuzeofficlal, since none of them names a GPU run. Tested exact head
119addf(on its base13f91ca).Tested
dxil.dllfrom Windows SDK 10.0.26100 (the loader's default), debug.cargo build --workspace --locked, thencargo test --workspace --locked --no-fail-fast -- --test-threads=4 --skip emit::memory_tests::heap_direct_texture_reads_mark_their_heap_index --skip descriptor::host::tests::dynamic_slots_are_held_until_released --skip memory::tests::lists_share_a_table_and_copies_keep_their_views --skip emit::stride_tests::a_heap_buffer_read_by_element_takes_the_views_stride --skip emit::stride_tests::a_heap_buffer_read_where_no_buffer_view_is_reads_zeros --skip emit::synthetic_tests::gathers_at_a_level_match_the_hardware: 775 passed, 0 failed, 9 ignored.matches_reference_at_length_and_block_boundaries,matches_reference_for_binary_state_sizes.--skipleaves out tests that fail on main63bcca4on this card too, not because of this PR:heap_direct_texture_reads_mark_their_heap_indexends thevictory-shadertest process with0xc0000005(#2571), so without the skip the rest of that crate never reports;dynamic_slots_are_held_until_released,lists_share_a_table_and_copies_keep_their_viewsand the twostride_testshit the 1,000,000-view heap cap of NVIDIA drivers (#1835, #2317);gathers_at_a_level_match_the_hardwarefails on lane 0 (#1744).Not tested
AI use
@cloph-dsp on GitHub · 2026-11-26 15:00 UTC · original
Independent verification of head
119addfon Windows, Rust 1.100.0/MSVC:cargo test --locked -p victory-game --lib -- cityhash::tests::matches_reference_at_length_and_block_boundaries --exact— 1 passed, 0 failed, 16 filtered.git diff --checkagainst merge base — clean.CPU-only synthetic reference comparison; worktree-local
CARGO_TARGET_DIR. AI-assisted (Hy4 flash). GPU/driver N/A. No game data used.@Dukestar69 on GitHub · 2026-11-26 18:10 UTC · original · approved these changes
Reviewed and verified locally on Windows 11 x64:
cargo test -p victory-game -- --test-threads=1: 17 passed, 0 failed (includingmatches_reference_at_length_and_block_boundariesandmatches_reference_for_binary_state_sizes).cargo clippy -p victory-game --all-targets -- -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.