From 1a975bc278fc7869aa2fdf4255bc2754ee9fc72b Mon Sep 17 00:00:00 2001 From: Karol Herbst Date: Sun, 11 Jun 2023 14:36:06 +0200 Subject: [PATCH] lp: align memory for long16 CL types Fixes following OpenCL CTS test flakes: basic kernel_memory_alignment_constant basic kernel_memory_alignment_global vectors vec_align_array vectors vec_align_struct_arr Signed-off-by: Karol Herbst Reviewed-by: Dave Airlie Part-of: --- src/gallium/drivers/llvmpipe/lp_texture.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/drivers/llvmpipe/lp_texture.c b/src/gallium/drivers/llvmpipe/lp_texture.c index c787167..426a4b7 100644 --- a/src/gallium/drivers/llvmpipe/lp_texture.c +++ b/src/gallium/drivers/llvmpipe/lp_texture.c @@ -288,7 +288,7 @@ llvmpipe_resource_create_all(struct pipe_screen *_screen, lpr->size_required += (LP_RASTER_BLOCK_SIZE - 1) * 4 * sizeof(float); if (alloc_backing) { - uint64_t alignment = 64; + uint64_t alignment = sizeof(uint64_t) * 16; if (templat->flags & PIPE_RESOURCE_FLAG_MAP_PERSISTENT) os_get_page_size(&alignment); -- 2.7.4