vkback: count reads of a slot held null for a new image's memory #236
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/vktory6--VKtory!236
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-236"
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?
@lordra9-svg on GitHub · 2026-12-02 15:18 UTC · original
lordra9-svg:fix/held-new-sampled→main· +132 −6 · 5 files · 1 commits · merged 2026-12-02 17:36 UTCWhat
docs/TASKS.md:626"Newly made images show empty for a frame": measure whether the 100k slot holds are actually seen by draws.arena::hold_newnulls a slot that would show an image made while earlier batches may still run (direct-descriptor device-loss guard); the TASKS note says the visual impact is a candidate, not proven.Change (instrumentation only)
Arenaownsheld_new(the same addresses aslater) andheld_read_now;hold_new/take_retry_slotsusehold/release, which keep a slot held while a later entry for it is pending.slot_read_at/slot_read_at_indexaskarena.held_read(addr): oneHashSet::containson the read path, no lock; a hit counts reads and marks the slot for the present.heldreadcounters and a stats part:reads of a slot held null for a new image's memory {reads} ({distinct} distinct slots so far). Distinct is summed per present.Measured (b7fixed, clean run)
slots retried after a refusal 102728, allhold_new(theExit::Retrycauses are ~2).reads of a slot held null ... 5958 (5718 distinct slots)— ~2.7 slot reads/present actually sample the null before the retry, so the one-frame pop is real but small, not the 100k the retry count suggests.Verified
cargo test -p vkback --lib: 169 passed (newa_held_slot_counts_reads_until_its_serial_passed); policy 6; clippy-D warningsclean;tools/build.shexit 0.Next (not in this PR)
Decide whether the ~6k sampled-null reads justify the device-loss-sensitive fix: keep the old descriptor (and hold its view/image alive) while the new image's memory is fresh, as victory-gpu's
keep/kin, instead of nulling. That needs a validation + device-loss A/B, so it should be its own change.@vktory6 on GitHub · 2026-12-02 17:37 UTC · original
Merged, thanks: the count tells whether draws actually read the slots held null for new images (TASKS "Newly made images show empty for a frame").