Fixes ESEXT-CTS.draw_elements_base_vertex_tests.AEP_shader_stages and ESEXT-CTS.texture_cube_map_array.texture_size_tesselation_con_sh.
Signed-off-by: Kenneth Graunke <kenn...@whitecape.org> --- src/compiler/glsl/ast_to_hir.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/compiler/glsl/ast_to_hir.cpp b/src/compiler/glsl/ast_to_hir.cpp index 0a23195..90cc924 100644 --- a/src/compiler/glsl/ast_to_hir.cpp +++ b/src/compiler/glsl/ast_to_hir.cpp @@ -5127,7 +5127,14 @@ ast_declarator_list::hir(exec_list *instructions, const glsl_type *const t = (earlier == NULL) ? var->type : earlier->type; - if (t->is_unsized_array()) + /* GL_OES_tessellation_shader allows omitting the array size + * for TCS inputs/outputs and TES inputs. Ignore this check. + */ + bool unsized_ok = state->stage == MESA_SHADER_TESS_CTRL || + (state->stage == MESA_SHADER_TESS_EVAL && + var->data.mode == ir_var_shader_in); + + if (t->is_unsized_array() && !unsized_ok) /* Section 10.17 of the GLSL ES 1.00 specification states that * unsized array declarations have been removed from the language. * Arrays that are sized using an initializer are still explicitly -- 2.9.3 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev