mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-17 20:09:57 -04:00
Retire textures evicted by disuse before freeing them, take them back on any use, and add tex_disuse = 2 to tell the freeing from the marks.
0.6.1.14 faulted the GPU (a read of an invalid address in a pass) about 30 seconds after its last disuse evictions, and no path by which an evicted image is still read was found in the code. An evicted texture is now first retired: the pool refresh gives its slots the stand-in while the image stays whole. It is destroyed only once the texture pool has taken every set of its ring since and the GPU has finished the submissions recorded until then, so no pool set can still be bound with its view. A mark on one of its slots or any lookup outside the pool refresh takes it back as it is, and the perf line counts those, which shows whether the marks miss a real use. tex_disuse = 2 retires and never frees, so the next fault can be put on the freeing or on the marks and stand-ins. The registration shortcut also read a slot's cached entry without checking that the resolution was current, so it could read the record of a destroyed texture; it now checks the slot's generation first. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 4c5b2ae2e030ab00a910d8f071c030e610fd78e1)
This commit is contained in:
@@ -152,6 +152,7 @@
|
||||
# 1: shaders mark the textures they sample, so that while video memory or the system's memory runs low, textures no
|
||||
# shader sampled for a while go, even those the game keeps registered (the areas it has loaded); one sampled again is
|
||||
# made again within a few frames. The first start after changing it builds the pipelines again. 0: such textures stay.
|
||||
# 2 (diagnosis): the same marks, and such textures give way to stand-ins in the texture pool, but none is freed.
|
||||
# tex_disuse = 1
|
||||
# Host zstd decoder in place of the game's (0 = the game's), and a check that decodes every call both ways and logs
|
||||
# the differences (1 = on; slow). Ocarina of Time 1.1.1 keeps the game's decoder while zstd_native is unset: its host
|
||||
|
||||
Reference in New Issue
Block a user