GPU diagnostics: order tied drop counts consistently #356

Merged
FIocker merged 1 commit from upstream-pr/356 into main 2026-11-24 08:02:22 +00:00
FIocker commented 2026-11-24 02:34:22 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by FIocker on 2026-11-24T02:34:22Z.


Rank diagnostic drop reasons by count descending and reason ascending. The frame report shows up to 40 reasons, so equal counts previously let the HashMap iteration order change which entries appeared at the cutoff. A deterministic tie-break makes reports easier to compare across runs.

Refs #293.

On Windows, cargo test --locked -p victory-gpu --features diagnostics pipeline::tests passed 3 tests. git diff --check and the staged asset-policy check passed.

<!-- greyfinch-sync:Marvisak/VIctory:issue:6573323595 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/356). Originally posted by [FIocker](https://github.com/FIocker) on 2026-11-24T02:34:22Z. --- Rank diagnostic drop reasons by count descending and reason ascending. The frame report shows up to 40 reasons, so equal counts previously let the HashMap iteration order change which entries appeared at the cutoff. A deterministic tie-break makes reports easier to compare across runs. Refs #293. On Windows, `cargo test --locked -p victory-gpu --features diagnostics pipeline::tests` passed 3 tests. `git diff --check` and the staged asset-policy check passed.
mercuryVM commented 2026-11-24 06:52:34 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by mercuryVM on 2026-11-24T06:40:39Z.

Review: APPROVED


Tested efb3e3d on Windows 11, RTX 5070, MSVC: cargo test --workspace --no-fail-fast passes (264 passed, 0 failed), and cargo test -p victory-gpu --features diagnostics --lib pipeline::tests passes (3).

Count descending, then reason ascending, is a total order on (String, count), so sort_unstable_by is deterministic here. Which reasons make the 40-entry cutoff no longer depends on HashMap order. No issues.

AI-assisted (Claude Code).

<!-- greyfinch-sync:Marvisak/VIctory:review:6034775118 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/356#pullrequestreview-6034775118). Originally posted by [mercuryVM](https://github.com/mercuryVM) on 2026-11-24T06:40:39Z. **Review:** APPROVED --- Tested efb3e3d on Windows 11, RTX 5070, MSVC: `cargo test --workspace --no-fail-fast` passes (264 passed, 0 failed), and `cargo test -p victory-gpu --features diagnostics --lib pipeline::tests` passes (3). Count descending, then reason ascending, is a total order on `(String, count)`, so `sort_unstable_by` is deterministic here. Which reasons make the 40-entry cutoff no longer depends on `HashMap` order. No issues. AI-assisted (Claude Code).
jeremygold02 commented 2026-11-24 06:55:48 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by jeremygold02 on 2026-11-24T04:26:24Z.


Tested PR #356 at head efb3e3d3da6deb6aa61e2e5efb7ded4af358d233 (state at test time: OPEN). Pre-comment refresh: state OPEN, head unchanged at efb3e3d3da6deb6aa61e2e5efb7ded4af358d233.

  • cargo test --locked -p victory-gpu --features diagnostics pipeline:: — passed (ok. 6 passed; 0 failed; 0 ignored; 0 measured; 40 filtered out; finished in 0.55s ); cases: pipeline::library::tests::names_change_with_what_goes_into_the_pipeline, pipeline::tests::skip_hashes_accepts_full_hashes_only, pipeline::tests::pipelines_keep_their_shaders, pipeline::tests::streams_yield_their_shaders, and 2 more.

Behavior covered: The pipeline test module passed, but these tests do not assert the new equal-count ordering in take_drops; this run verifies the surrounding diagnostics module builds and its six existing tests pass.
Code: crates/victory-gpu/src/pipeline.rs

<!-- greyfinch-sync:Marvisak/VIctory:comment:7122020477 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/356#issuecomment-7122020477). Originally posted by [jeremygold02](https://github.com/jeremygold02) on 2026-11-24T04:26:24Z. --- Tested PR #356 at head `efb3e3d3da6deb6aa61e2e5efb7ded4af358d233` (state at test time: OPEN). Pre-comment refresh: state OPEN, head unchanged at `efb3e3d3da6deb6aa61e2e5efb7ded4af358d233`. - `cargo test --locked -p victory-gpu --features diagnostics pipeline::` — passed (ok. 6 passed; 0 failed; 0 ignored; 0 measured; 40 filtered out; finished in 0.55s ); cases: pipeline::library::tests::names_change_with_what_goes_into_the_pipeline, pipeline::tests::skip_hashes_accepts_full_hashes_only, pipeline::tests::pipelines_keep_their_shaders, pipeline::tests::streams_yield_their_shaders, and 2 more. Behavior covered: The pipeline test module passed, but these tests do not assert the new equal-count ordering in `take_drops`; this run verifies the surrounding diagnostics module builds and its six existing tests pass. Code: [crates/victory-gpu/src/pipeline.rs](https://github.com/Marvisak/VIctory/blob/efb3e3d3da6deb6aa61e2e5efb7ded4af358d233/crates/victory-gpu/src/pipeline.rs)
upstream-sync closed this pull request 2026-11-24 09:05:22 +00:00
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
Marvisak/VIctory!356
No description provided.