i965: Don't allocate uniform space for samplers
Samplers are encoded into the instruction word, so there's no need to make space in the uniform file. Previously matrix_columns and vector_elements were set to 0, making this else case a no-op. Commit75a31a20afchanged that, causing malloc corruption in thousands of tests on i965. Fixes:75a31a20af("glsl: set vector_elements to 1 for samplers") Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=100871
This commit is contained in:
@@ -135,7 +135,7 @@ brw_nir_setup_glsl_uniform(gl_shader_stage stage, nir_variable *var,
|
||||
struct gl_uniform_storage *storage =
|
||||
&prog->sh.data->UniformStorage[u];
|
||||
|
||||
if (storage->builtin)
|
||||
if (storage->builtin || storage->type->is_sampler())
|
||||
continue;
|
||||
|
||||
if (strncmp(var->name, storage->name, namelen) != 0 ||
|
||||
|
||||
Reference in New Issue
Block a user