From 507626304c047dacb959feaf94ff520a4e9f6c60 Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Fri, 15 Jul 2016 16:57:06 -0700 Subject: [PATCH] glsl/nir: Call nir_lower_constant_initializers Reviewed-by: Iago Toral Quiroga --- src/compiler/glsl/glsl_to_nir.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/compiler/glsl/glsl_to_nir.cpp b/src/compiler/glsl/glsl_to_nir.cpp index 0b74b7e5aa3..f60139c2f2a 100644 --- a/src/compiler/glsl/glsl_to_nir.cpp +++ b/src/compiler/glsl/glsl_to_nir.cpp @@ -144,6 +144,8 @@ glsl_to_nir(const struct gl_shader_program *shader_prog, v2.run(sh->ir); visit_exec_list(sh->ir, &v1); + nir_lower_constant_initializers(shader, (nir_variable_mode)~0); + shader->info->name = ralloc_asprintf(shader, "GLSL%d", shader_prog->Name); if (shader_prog->Label) shader->info->label = ralloc_strdup(shader, shader_prog->Label); -- 2.30.2