pan/bi: Change texel buffer limits
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run

Increase texel buffer size limit and lower uniform texel buffer alignment limit.

Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38490>
This commit is contained in:
Lars-Ivar Hesselberg Simonsen 2025-11-17 16:37:26 +01:00
parent a21ee564e2
commit 4db7958edc
2 changed files with 6 additions and 8 deletions

View file

@ -251,7 +251,7 @@ pan_get_max_texel_buffer_elements(unsigned arch)
/* TODO 1<<27 can be made larger for v11+ with a refactor of the buffer /* TODO 1<<27 can be made larger for v11+ with a refactor of the buffer
* path away from using image logic. */ * path away from using image logic. */
return 1 << 27; return 1 << 27;
else if (arch >= 9) else if (arch >= 6)
return 1 << 27; return 1 << 27;
else else
return 65536; return 65536;

View file

@ -641,12 +641,10 @@ panvk_per_arch(get_physical_device_properties)(
.maxImageDimension3D = PAN_ARCH <= 10 ? (1 << 9) : (1 << 14), .maxImageDimension3D = PAN_ARCH <= 10 ? (1 << 9) : (1 << 14),
.maxImageDimensionCube = PAN_ARCH <= 10 ? (1 << 14) - 1 : (1 << 16), .maxImageDimensionCube = PAN_ARCH <= 10 ? (1 << 14) - 1 : (1 << 16),
.maxImageArrayLayers = (1 << 16), .maxImageArrayLayers = (1 << 16),
/* Currently Bifrost is limited by the 1D texture size, which is 2^16, /* Pre-v11 is limited to 2^27 elements of 16 byte formats due to
while pre-v11 is limited to 2^27 elements of 16 byte formats due to
size fields of 32 bits. */ size fields of 32 bits. */
.maxTexelBufferElements = PAN_ARCH >= 11 ? PANVK_MAX_BUFFER_SIZE .maxTexelBufferElements =
: PAN_ARCH >= 9 ? (1 << 27) PAN_ARCH >= 11 ? PANVK_MAX_BUFFER_SIZE : (1 << 27),
: (1 << 16),
/* Each uniform entry is 16-byte and the number of entries is encoded in a /* Each uniform entry is 16-byte and the number of entries is encoded in a
* 12-bit field, with the minus(1) modifier, which gives 2^20. * 12-bit field, with the minus(1) modifier, which gives 2^20.
*/ */
@ -986,8 +984,8 @@ panvk_per_arch(get_physical_device_properties)(
.integerDotProductAccumulatingSaturating64BitMixedSignednessAccelerated = false, .integerDotProductAccumulatingSaturating64BitMixedSignednessAccelerated = false,
.storageTexelBufferOffsetAlignmentBytes = 64, .storageTexelBufferOffsetAlignmentBytes = 64,
.storageTexelBufferOffsetSingleTexelAlignment = false, .storageTexelBufferOffsetSingleTexelAlignment = false,
.uniformTexelBufferOffsetAlignmentBytes = PAN_ARCH >= 9 ? 4 : 64, .uniformTexelBufferOffsetAlignmentBytes = 4,
.uniformTexelBufferOffsetSingleTexelAlignment = PAN_ARCH >= 9, .uniformTexelBufferOffsetSingleTexelAlignment = true,
.maxBufferSize = PANVK_MAX_BUFFER_SIZE, .maxBufferSize = PANVK_MAX_BUFFER_SIZE,
/* Vulkan 1.4 properties */ /* Vulkan 1.4 properties */