summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/glsl/opt_dead_code.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/glsl/opt_dead_code.cpp b/src/glsl/opt_dead_code.cpp
index 04e4d5673d2..e4bf874700c 100644
--- a/src/glsl/opt_dead_code.cpp
+++ b/src/glsl/opt_dead_code.cpp
@@ -126,6 +126,9 @@ do_dead_code(exec_list *instructions, bool uniform_locations_assigned)
if (block_type->interface_packing != GLSL_INTERFACE_PACKING_PACKED)
continue;
}
+
+ if (entry->var->type->is_subroutine())
+ continue;
}
entry->var->remove();