Mesa (glsl2): glsl2: Use ir_dead_code's linked version after linking.

Eric Anholt anholt at kemper.freedesktop.org
Tue Jul 27 11:49:59 PDT 2010


Module: Mesa
Branch: glsl2
Commit: bf6ad0ab3d3940ca642c388444f7ddae91eefffc
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=bf6ad0ab3d3940ca642c388444f7ddae91eefffc

Author: Eric Anholt <eric at anholt.net>
Date:   Tue Jul 27 11:31:12 2010 -0700

glsl2: Use ir_dead_code's linked version after linking.

glsl-fs-raytrace-bug27060 goes from 485 Mesa IR instructions to 389
before Mesa IR optimization.

---

 src/glsl/linker.cpp |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp
index ea0274e..06f2a82 100644
--- a/src/glsl/linker.cpp
+++ b/src/glsl/linker.cpp
@@ -1262,9 +1262,7 @@ link_shaders(struct gl_shader_program *prog)
 	 progress = do_if_simplification(ir) || progress;
 	 progress = do_copy_propagation(ir) || progress;
 	 progress = do_dead_code_local(ir) || progress;
-#if 0
-	 progress = do_dead_code_unlinked(state, ir) || progress;
-#endif
+	 progress = do_dead_code_unlinked(ir) || progress;
 	 progress = do_constant_variable_unlinked(ir) || progress;
 	 progress = do_constant_folding(ir) || progress;
 	 progress = do_if_return(ir) || progress;



More information about the mesa-commit mailing list