aboutsummaryrefslogtreecommitdiffstats
path: root/src/glsl/ir_rvalue_visitor.cpp
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2015-02-23 22:00:34 -0800
committerKenneth Graunke <[email protected]>2015-02-24 15:24:52 -0800
commit44b45da994c5d827eb123fb18b501d712822baae (patch)
tree412de9c43f5dcd8fd352b22944113f3f6aac4cd8 /src/glsl/ir_rvalue_visitor.cpp
parent926d8b05107f4f5fecad41ad30833a306a566303 (diff)
glsl: Make ir_rvalue_visitor visit ir_discard::condition.
This was forgotten. I omitted the NULL check since we don't check ir_assignment::condition either. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Connor Abbott <[email protected]> Reviewed-by: Matt Turner <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
Diffstat (limited to 'src/glsl/ir_rvalue_visitor.cpp')
-rw-r--r--src/glsl/ir_rvalue_visitor.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/glsl/ir_rvalue_visitor.cpp b/src/glsl/ir_rvalue_visitor.cpp
index 34cdb1c98a0..2eee3da7b22 100644
--- a/src/glsl/ir_rvalue_visitor.cpp
+++ b/src/glsl/ir_rvalue_visitor.cpp
@@ -135,6 +135,13 @@ ir_rvalue_base_visitor::rvalue_visit(ir_call *ir)
}
ir_visitor_status
+ir_rvalue_base_visitor::rvalue_visit(ir_discard *ir)
+{
+ handle_rvalue(&ir->condition);
+ return visit_continue;
+}
+
+ir_visitor_status
ir_rvalue_base_visitor::rvalue_visit(ir_return *ir)
{
handle_rvalue(&ir->value);;
@@ -205,6 +212,12 @@ ir_rvalue_visitor::visit_leave(ir_call *ir)
}
ir_visitor_status
+ir_rvalue_visitor::visit_leave(ir_discard *ir)
+{
+ return rvalue_visit(ir);
+}
+
+ir_visitor_status
ir_rvalue_visitor::visit_leave(ir_return *ir)
{
return rvalue_visit(ir);
@@ -271,6 +284,12 @@ ir_rvalue_enter_visitor::visit_enter(ir_call *ir)
}
ir_visitor_status
+ir_rvalue_enter_visitor::visit_enter(ir_discard *ir)
+{
+ return rvalue_visit(ir);
+}
+
+ir_visitor_status
ir_rvalue_enter_visitor::visit_enter(ir_return *ir)
{
return rvalue_visit(ir);