From fb972ed4e51f7570210b523264e927a378265a2a Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Thu, 12 Oct 2017 05:10:53 +0100 Subject: radv: take unsafe_math and sisched into account when hashing shaders. We want to generate different variants for sisched and unsafe_math shader variants, so add them to the hash key. Reviewed-by: Samuel Pitoiset Reviewed-by: Timothy Arceri Signed-off-by: Dave Airlie --- src/amd/vulkan/radv_private.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/amd/vulkan/radv_private.h') diff --git a/src/amd/vulkan/radv_private.h b/src/amd/vulkan/radv_private.h index e58fb2175e2..70c5c70aaa5 100644 --- a/src/amd/vulkan/radv_private.h +++ b/src/amd/vulkan/radv_private.h @@ -962,13 +962,16 @@ struct radv_event { struct radv_shader_module; struct ac_shader_variant_key; +#define RADV_HASH_SHADER_IS_GEOM_COPY_SHADER (1 << 0) +#define RADV_HASH_SHADER_SISCHED (1 << 1) +#define RADV_HASH_SHADER_UNSAFE_MATH (1 << 2) void radv_hash_shader(unsigned char *hash, struct radv_shader_module *module, const char *entrypoint, const VkSpecializationInfo *spec_info, const struct radv_pipeline_layout *layout, const struct ac_shader_variant_key *key, - uint32_t is_geom_copy_shader); + uint32_t flags); static inline gl_shader_stage vk_to_mesa_shader_stage(VkShaderStageFlagBits vk_stage) -- cgit v1.2.3