aboutsummaryrefslogtreecommitdiff
path: root/src/video_core/host1x/codecs/codec.cpp
diff options
context:
space:
mode:
authorTakoroka <137927095+Takoroka@users.noreply.github.com>2026-10-30 05:16:34 -0400
committerTakoroka <137927095+Takoroka@users.noreply.github.com>2026-10-30 05:16:34 -0400
commit862ab88831e5e6abd3d7e03f26a7cfed36a3dc16 (patch)
tree2e95f099c659e4e534d9479b62ace1413443a20f /src/video_core/host1x/codecs/codec.cpp
parentbed068523eb066b843a60cfdd3156adafce8904a (diff)
texture_cache: give images over unwritten sparse blocks no device memory
Mario Kart World creates nine terrain layer pools in sparse regions (four R8 16384x16384, four RG16 8192x8192, one R16 8192x8192: 2.9 GB of device memory). In 180 s of title and attract demo not one of their blocks is written and nothing renders into them, so they hold zeros; on the console only the few tiles the game maps have memory. nx2:gpu now publishes which 4 MiB blocks of each sparse region have been written (nx2.h, a leaf lock the texture cache may take). An image of 32 MiB or more lying in one sparse region with no written block is created as a sparse resident image with nothing bound: reads return zero, as an unmapped tile does. The first write into its range, or the first time the GPU renders into it (that range then counts as written), marks it remapped, so a backed image replaces it at its next use. Mario Kart World, 180 s: the collector deletes 0-80 images per 600 frames instead of thousands, frames over 100 ms per 600 presents drop from 1-9 to 0-1, peak working set 14.7 GB. One render target in a small sparse region gets replaced once (logged).
Diffstat (limited to 'src/video_core/host1x/codecs/codec.cpp')
0 files changed, 0 insertions, 0 deletions