bool
fs_visitor::run()
{
+ sanity_param_count = fp->Base.Parameters->NumParameters;
uint32_t orig_nr_params = c->prog_data.nr_params;
if (intel->gen >= 6)
(void) orig_nr_params;
}
+ /* If any state parameters were appended, then ParameterValues could have
+ * been realloced, in which case the driver uniform storage set up by
+ * _mesa_associate_uniform_storage() would point to freed memory. Make
+ * sure that didn't happen.
+ */
+ assert(sanity_param_count == fp->Base.Parameters->NumParameters);
+
return !failed;
}
const struct gl_fragment_program *fp;
struct brw_wm_compile *c;
+ unsigned int sanity_param_count;
/* Delayed setup of c->prog_data.params[] due to realloc of
* ParamValues[] during compile.
bool
vec4_visitor::run()
{
+ sanity_param_count = vp->Base.Parameters->NumParameters;
+
if (INTEL_DEBUG & DEBUG_SHADER_TIME)
emit_shader_time_begin();
break;
}
+ /* If any state parameters were appended, then ParameterValues could have
+ * been realloced, in which case the driver uniform storage set up by
+ * _mesa_associate_uniform_storage() would point to freed memory. Make
+ * sure that didn't happen.
+ */
+ assert(sanity_param_count == vp->Base.Parameters->NumParameters);
+
return !failed;
}
const struct gl_vertex_program *vp;
struct brw_vs_compile *c;
struct brw_vs_prog_data *prog_data;
+ unsigned int sanity_param_count;
char *fail_msg;
bool failed;