nvc0/ir: fix lowering of textureGrad
[mesa.git] / src / glsl / loop_analysis.h
index 893dd46db04d34af00cd2fdfa1a399c1ebfc708e..8bed1db02106368e78d6c333bd8ae3fde6948a68 100644 (file)
@@ -57,7 +57,7 @@ set_loop_controls(exec_list *instructions, loop_state *ls);
 
 
 extern bool
-unroll_loops(exec_list *instructions, loop_state *ls);
+unroll_loops(exec_list *instructions, loop_state *ls, unsigned max_iterations);
 
 
 /**
@@ -122,10 +122,16 @@ public:
     */
    unsigned num_loop_jumps;
 
+   /**
+    * Whether this loop contains any function calls.
+    */
+   bool contains_calls;
+
    loop_variable_state()
    {
       this->max_iterations = -1;
       this->num_loop_jumps = 0;
+      this->contains_calls = false;
       this->var_hash = hash_table_ctor(0, hash_table_pointer_hash,
                                       hash_table_pointer_compare);
    }
@@ -214,6 +220,8 @@ public:
 
    loop_variable_state *insert(ir_loop *ir);
 
+   bool loop_found;
+
 private:
    loop_state();