summaryrefslogtreecommitdiff
path: root/src/glsl/ir_optimization.h
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2010-06-25 13:38:38 -0700
committerEric Anholt <eric@anholt.net>2010-06-25 13:38:38 -0700
commitbda27424cf04c0d2ec2b49c56f562d5b2d2f0bff (patch)
treedef596e4d7ba78af3bf590e785d76f9260100802 /src/glsl/ir_optimization.h
parentabc4e52992c53ee6b6895480b47e6a6e27ef9bd0 (diff)
glsl2: Use the parser state as the talloc context for dead code elimination.
This cuts runtime by around 20% from talloc_parent() lookups.
Diffstat (limited to 'src/glsl/ir_optimization.h')
-rw-r--r--src/glsl/ir_optimization.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/glsl/ir_optimization.h b/src/glsl/ir_optimization.h
index 432a33458c..147f92176b 100644
--- a/src/glsl/ir_optimization.h
+++ b/src/glsl/ir_optimization.h
@@ -32,9 +32,11 @@ bool do_constant_folding(exec_list *instructions);
bool do_constant_variable(exec_list *instructions);
bool do_constant_variable_unlinked(exec_list *instructions);
bool do_copy_propagation(exec_list *instructions);
-bool do_dead_code(exec_list *instructions);
+bool do_dead_code(struct _mesa_glsl_parse_state *state,
+ exec_list *instructions);
bool do_dead_code_local(exec_list *instructions);
-bool do_dead_code_unlinked(exec_list *instructions);
+bool do_dead_code_unlinked(struct _mesa_glsl_parse_state *state,
+ exec_list *instructions);
bool do_function_inlining(exec_list *instructions);
bool do_if_simplification(exec_list *instructions);
bool do_swizzle_swizzle(exec_list *instructions);