From 6e5eb0afd3f97937262db0bbd4f13aff76785015 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Briano?= Date: Thu, 15 Jun 2023 16:22:53 -0700 Subject: [PATCH] anv: do not explode on 32 bit builds Fixes: 930e862af7a ("anv: add shaders for copying query results") Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/9213 Reviewed-by: Lionel Landwerlin Part-of: --- src/intel/vulkan/anv_internal_kernels.h | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/intel/vulkan/anv_internal_kernels.h b/src/intel/vulkan/anv_internal_kernels.h index 7dce6e549f3..de951d27576 100644 --- a/src/intel/vulkan/anv_internal_kernels.h +++ b/src/intel/vulkan/anv_internal_kernels.h @@ -104,16 +104,21 @@ struct anv_query_copy_shader_params { uint32_t num_items; /* First query to copy result from */ - uint query_base; + uint32_t query_base; /* Query stride in bytes */ - uint query_stride; + uint32_t query_stride; /* Offset at which the data should be read from */ - uint query_data_offset; + uint32_t query_data_offset; /* Stride of destination writes */ - uint destination_stride; + uint32_t destination_stride; + + /* We need to be 64 bit aligned, or 32 bit builds get + * very unhappy. + */ + uint32_t padding; }; struct anv_query_copy_params {