glsl/loops: Remove unnecessary list walk from loop_control_visitor.
authorPaul Berry <stereotype441@gmail.com>
Thu, 28 Nov 2013 20:44:53 +0000 (12:44 -0800)
committerPaul Berry <stereotype441@gmail.com>
Mon, 9 Dec 2013 18:54:49 +0000 (10:54 -0800)
commit714e1b331ed1b2dfffac4accb4ebf5a01d3f961f
tree55e28f094eda50017c627a9fc694665bb4159065
parent115fd75ab06b858b83173f7d76eada8ea417fc86
glsl/loops: Remove unnecessary list walk from loop_control_visitor.

When loop_control_visitor::visit_leave(ir_loop *) is analyzing a loop
terminator that acts on a certain ir_variable, it doesn't need to walk
the list of induction variables to find the loop_variable entry
corresponding to the variable.  It can just look it up in the
loop_variable_state hashtable and verify that the loop_variable entry
represents an induction variable.

Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
src/glsl/loop_analysis.h
src/glsl/loop_controls.cpp