aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/program
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/mesa/program')
-rw-r--r--mesalib/src/mesa/program/ir_to_mesa.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/mesalib/src/mesa/program/ir_to_mesa.cpp b/mesalib/src/mesa/program/ir_to_mesa.cpp
index 77946ad13..aa5f007e9 100644
--- a/mesalib/src/mesa/program/ir_to_mesa.cpp
+++ b/mesalib/src/mesa/program/ir_to_mesa.cpp
@@ -2754,6 +2754,9 @@ ir_to_mesa_visitor::copy_propagate(void)
*/
for (int r = 0; r < this->next_temp; r++) {
for (int c = 0; c < 4; c++) {
+ if (!acp[4 * r + c])
+ continue;
+
if (acp[4 * r + c]->src_reg[0].file == PROGRAM_OUTPUT)
acp[4 * r + c] = NULL;
}