glsl2: Use ir_dead_code's linked version after linking.
authorEric Anholt <eric@anholt.net>
Tue, 27 Jul 2010 18:31:12 +0000 (11:31 -0700)
committerEric Anholt <eric@anholt.net>
Tue, 27 Jul 2010 18:49:27 +0000 (11:49 -0700)
glsl-fs-raytrace-bug27060 goes from 485 Mesa IR instructions to 389
before Mesa IR optimization.

src/glsl/linker.cpp

index ea0274eac33d96381d342c94d14ef6459e355e55..06f2a8231a9e81fa2ed3dc7f6d00d9982c9cf16e 100644 (file)
@@ -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;