aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/glsl/opt_constant_propagation.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/glsl/opt_constant_propagation.cpp')
-rw-r--r--mesalib/src/glsl/opt_constant_propagation.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/mesalib/src/glsl/opt_constant_propagation.cpp b/mesalib/src/glsl/opt_constant_propagation.cpp
index 1fff71753..814f6e61f 100644
--- a/mesalib/src/glsl/opt_constant_propagation.cpp
+++ b/mesalib/src/glsl/opt_constant_propagation.cpp
@@ -400,11 +400,8 @@ ir_constant_propagation_visitor::add_constant(ir_assignment *ir)
{
acp_entry *entry;
- if (ir->condition) {
- ir_constant *condition = ir->condition->as_constant();
- if (!condition || !condition->value.b[0])
- return;
- }
+ if (ir->condition)
+ return;
if (!ir->write_mask)
return;