From: Samuel Pitoiset Date: Mon, 14 May 2018 14:04:33 +0000 (+0200) Subject: radv: check that layout isn't NULL in radv_nir_shader_info_pass() X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7cbc6f2621f6d91b7bb201b9539ebff0f903828a;p=mesa.git radv: check that layout isn't NULL in radv_nir_shader_info_pass() An upcoming patch will run the shader info pass on the geometry shader just before emitting the GS copy shader. Signed-off-by: Samuel Pitoiset Reviewed-by: Bas Nieuwenhuizen --- diff --git a/src/amd/vulkan/radv_shader_info.c b/src/amd/vulkan/radv_shader_info.c index aa06efc9dc7..a436bd75343 100644 --- a/src/amd/vulkan/radv_shader_info.c +++ b/src/amd/vulkan/radv_shader_info.c @@ -424,7 +424,7 @@ radv_nir_shader_info_pass(const struct nir_shader *nir, struct nir_function *func = (struct nir_function *)exec_list_get_head_const(&nir->functions); - if (options->layout->dynamic_offset_count) + if (options->layout && options->layout->dynamic_offset_count) info->loads_push_constants = true; nir_foreach_variable(variable, &nir->inputs)