Some drivers fail device memory allocations past 256 MiB even where maxMemoryAllocationSize is larger (NVIDIA's on
FreeBSD), and a texture can be bigger once decoded: a 2D ASTC texture of 11584x11584, or a 3D one of 512^3, is
512 MiB of RGBA8. vk/memory.c caps every allocation at 256 MiB (or maxMemoryAllocationSize, when smaller):
sparseBinding feature on the graphics queue's family; without it the image gets one allocation, which the
driver may still accept.texture.c stages a level bigger than 64 MiB (or the
cap) in bands of block rows of one slice, converted band by band.devmem.c) stay within the cap.The [Debug] setting vk_max_allocation_mb (--vk-max-allocation-mb=4 for a run) lowers the cap, to test the pieces on a driver that accepts anything (lavapipe).
Made from docs/layers/gpu/astc.md at 69237645142c. GPL-3.0-or-later.