glsl: Remove integer matrix support from ir_dereference_array::constant_expression_value

It looks like this code has existed since day 1, but I have no idea why.
There have never been integer matrices in GLSL.

Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5135>
This commit is contained in:
Ian Romanick
2020-05-20 13:39:57 -07:00
parent 22979f90d9
commit 685e79a64b
+1 -9
View File
@@ -867,13 +867,6 @@ ir_dereference_array::constant_expression_value(void *mem_ctx,
ir_constant_data data = { { 0 } };
switch (column_type->base_type) {
case GLSL_TYPE_UINT:
case GLSL_TYPE_INT:
for (unsigned i = 0; i < column_type->vector_elements; i++)
data.u[i] = array->value.u[mat_idx + i];
break;
case GLSL_TYPE_FLOAT:
for (unsigned i = 0; i < column_type->vector_elements; i++)
data.f[i] = array->value.f[mat_idx + i];
@@ -887,8 +880,7 @@ ir_dereference_array::constant_expression_value(void *mem_ctx,
break;
default:
assert(!"Should not get here.");
break;
unreachable("Matrix types are either float or double.");
}
return new(mem_ctx) ir_constant(column_type, &data);