From: Jason Ekstrand Date: Wed, 13 Jul 2016 18:35:24 +0000 (-0700) Subject: anv/pipeline: Assert that the number of uniforms from NIR fits X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1eed753ee8725baf41790d30f94bc3567653c28c;p=mesa.git anv/pipeline: Assert that the number of uniforms from NIR fits --- diff --git a/src/intel/vulkan/anv_pipeline.c b/src/intel/vulkan/anv_pipeline.c index 29747cf6c4a..3723423617b 100644 --- a/src/intel/vulkan/anv_pipeline.c +++ b/src/intel/vulkan/anv_pipeline.c @@ -329,6 +329,7 @@ anv_pipeline_compile(struct anv_pipeline *pipeline, /* If the shader uses any push constants at all, we'll just give * them the maximum possible number */ + assert(nir->num_uniforms <= MAX_PUSH_CONSTANTS_SIZE); prog_data->nr_params += MAX_PUSH_CONSTANTS_SIZE / sizeof(float); }