Texture store: at most 8 textures wait for its thread (the copies piled up unbounded; #227) #288
No reviewers
Labels
No labels
accessibility
already-solved
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
merged
needs-decision
needs-game-run
needs-rebase
not-merged
nvidia
obsolete
question
security
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/avatarmanz--VIctory-7900XTX!288
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-288"
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?
@sharan104 on GitHub · 2026-11-26 14:31 UTC · original
sharan104:fix/texstore-bounded-queue→main· +51 −4 · 1 files · 1 commits · openRefs #227 (one of the items it lists as open to anyone).
texstore::keepsends a full copy of each texture's memory (tiled.to_vec()) over an unboundedmpsc::channelto the single "texture store" thread, which digests, detiles and writes each one. When textures arrive faster than that thread keeps up (streaming in a new area), the copies pile up in the channel with no limit: whole texture memories, held until the thread reaches them.Fix:
sync_channelofWAITING(8) jobs, filled withtry_send.seen, so it's stored the next time it's read whole. The store loses nothing; it just catches up later.seenand isn't copied again on every read.Test:
textures_wait_for_the_store_in_boundsqueues 13 textures into a channel nobody drains. Only the first 8 wait, and the other 5 are no longer inseen. With the receiver dropped, a texture stays seen. The test fails without theseenremoval and passed 10 runs out of 10.Results:
cargo test -p victory-gpu --lockedpasses, with and without--all-features.watch.rslint, which #241 fixes.This touches different lines of
texstore.rsfrom #283, which adds the asset-policy check to the store's folder. The two merge independently.🤖 Generated with Claude Code
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.