aboutsummaryrefslogtreecommitdiffstats
path: root/src/glsl/ir_optimization.h
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2010-07-06 18:09:39 -0700
committerEric Anholt <[email protected]>2010-07-07 09:10:48 -0700
commitd674ebcee0d2731e50d6530502cefcebc39dcdb6 (patch)
tree74feecda4fdc277c972e01267289a66cd45415f6 /src/glsl/ir_optimization.h
parent6de882334ac7f3d32d04261adfed1397e075ffd5 (diff)
glsl2: Add a pass to simplify if statements returning from both sides.
This allows function inlining making the following tests work even without function calls implemented: glsl-fs-functions-2 glsl-fs-functions-3 glsl-vs-functions glsl-vs-functions-2 glsl-vs-functions-3 glsl-vs-vec4-indexing-5 (Note that those tests were designed to trigger actual function calls, and this defeats them. However, those testcases ended up catching the bug in the previous commit.)
Diffstat (limited to 'src/glsl/ir_optimization.h')
-rw-r--r--src/glsl/ir_optimization.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/glsl/ir_optimization.h b/src/glsl/ir_optimization.h
index 93010dadbee..b03c0644cf0 100644
--- a/src/glsl/ir_optimization.h
+++ b/src/glsl/ir_optimization.h
@@ -39,6 +39,7 @@ bool do_dead_code_unlinked(struct _mesa_glsl_parse_state *state,
exec_list *instructions);
bool do_div_to_mul_rcp(exec_list *instructions);
bool do_function_inlining(exec_list *instructions);
+bool do_if_return(exec_list *instructions);
bool do_if_simplification(exec_list *instructions);
bool do_mod_to_fract(exec_list *instructions);
bool do_swizzle_swizzle(exec_list *instructions);