You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Images: the first image allocates a whole 1024x1024 atlas page #701
The first image an app draws allocates a whole IMAGE_ATLAS_SIZE (1024×1024) RGBA page, even if it's one 24 px icon. That's 4 MiB of pixels on the CPU and a 4 MiB texture.
On Vulkan it costs more than that. In our bar, the 4.2 MB texture didn't fit what was left of gpu-allocator's first block, so the next block was allocated at double the size (16 MiB), and i915 kept it resident. One tray icon added 16.9 MB of GPU memory (DRM fdinfo: 33.1 → 50.0 MB).
Fix: start a shelf page as tall as its first image and double its rows as needed, up to 1024. Slots never move, and the renderer already re-creates a page's texture when its size changes. With that, the bar with one icon is back to 33.1 MB, the same as with no image at all.
Related: #163 (the page's CPU copy), #80 (allocator block sizes).
Fixed on dev in #958 (3faa09fd). Image atlas shelf pages now start at max(128, height.next_power_of_two()) rows (512 KiB for small icons instead of 4 MiB) and double as shelves fill, up to 1024 rows.
Closing as completed. If you still see this on a current dev revision, comment here and it will be reopened.
Activity
Hona commentedon Nov 23, 2026
Fixed on
devin #958 (3faa09fd). Image atlas shelf pages now start atmax(128, height.next_power_of_two())rows (512 KiB for small icons instead of 4 MiB) and double as shelves fill, up to 1024 rows.Closing as completed. If you still see this on a current dev revision, comment here and it will be reopened.