BVH trace: a summary every 600 frames of copies made from stale sizes and copies landing on others #1413

Merged
Rafa7046 merged 1 commit from upstream-pr/1413 into main 2026-11-29 00:24:47 +00:00
Rafa7046 commented 2026-11-28 19:21:57 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Rafa7046 on 2026-11-28T19:21:57Z.


A diagnostics-only counter for #1412. It changes nothing unless VICTORY_BVH_TRACE=1 is set, in diagnostics builds.

With VICTORY_BVH_TRACE=1 the per-event lines stop after 6,000, about the first 130 frames. This adds a line every 600 frames that is not bounded by that count:

bvh trace summary: frames 17231-17831: 392 copies to a place of the compacted size, 1 of a structure whose size never came, 117 made while the size's place held another value (read stale), 222 landing on a copy of the same frame and 83 on one of the 10 before (59572 KB written over)
  • A copy to a place of the compacted size is the 32-thread copy with the third constant 0xc, as in every run I looked at.
  • "Read stale": when the copy is recorded, the slot its size was asked into holds another value than the size that came.
  • "Landing on": the copy's range, at the size that came, overlaps another such copy of the same frame or of the 10 before, at a different address.

fork-ray-tracing.md: the variable's row, and under the known gap, why a wait on our thread comes too late with VICTORY_ASYNC_SUBMIT, and what holding the title did (details in #1412).

Tested: RTX 5080, diag build on e7d8150, 8 sessions with the builder on, the line every ~10 s through each run.

Checks: cargo clippy -p victory-gpu --features diagnostics --lib reports nothing in memory.rs. The two manual_is_multiple_of hits in descriptor.rs and shadow.rs, and the bindings.ini hit of cargo xtask policy, are already on main.

Measurements and this change were prepared with an AI assistant (Claude Code); the runs were played on my machine.

🤖 Generated with Claude Code

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:5543745985 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1413). Originally posted by [Rafa7046](https://github.com/Rafa7046) on 2026-11-28T19:21:57Z. --- A diagnostics-only counter for #1412. It changes nothing unless `VICTORY_BVH_TRACE=1` is set, in diagnostics builds. With `VICTORY_BVH_TRACE=1` the per-event lines stop after 6,000, about the first 130 frames. This adds a line every 600 frames that is not bounded by that count: ``` bvh trace summary: frames 17231-17831: 392 copies to a place of the compacted size, 1 of a structure whose size never came, 117 made while the size's place held another value (read stale), 222 landing on a copy of the same frame and 83 on one of the 10 before (59572 KB written over) ``` - A copy to a place of the compacted size is the 32-thread copy with the third constant `0xc`, as in every run I looked at. - "Read stale": when the copy is recorded, the slot its size was asked into holds another value than the size that came. - "Landing on": the copy's range, at the size that came, overlaps another such copy of the same frame or of the 10 before, at a different address. `fork-ray-tracing.md`: the variable's row, and under the known gap, why a wait on our thread comes too late with `VICTORY_ASYNC_SUBMIT`, and what holding the title did (details in #1412). **Tested:** RTX 5080, diag build on `e7d8150`, 8 sessions with the builder on, the line every ~10 s through each run. **Checks:** `cargo clippy -p victory-gpu --features diagnostics --lib` reports nothing in `memory.rs`. The two `manual_is_multiple_of` hits in `descriptor.rs` and `shadow.rs`, and the `bindings.ini` hit of `cargo xtask policy`, are already on `main`. Measurements and this change were prepared with an AI assistant (Claude Code); the runs were played on my machine. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
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
trustno1-coder/VIctory-NVIDIA!1413
No description provided.