summaryrefslogtreecommitdiffstats
path: root/src/glsl/ir_hierarchical_visitor.cpp
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2010-07-01 10:09:58 -0700
committerEric Anholt <[email protected]>2010-07-01 11:07:23 -0700
commit8a1f186cc55979bb9df0a88b48da8d81460c3e7c (patch)
tree7a39126f77b75f94c09f441fdbca6c2be57d34cb /src/glsl/ir_hierarchical_visitor.cpp
parent9acf618f24428eba72650c0e328e7ed52986728e (diff)
glsl2: Add a pass to convert mod(a, b) to b * fract(a/b).
This is used by the Mesa IR backend to implement mod, fixing glsl-fs-mod.
Diffstat (limited to 'src/glsl/ir_hierarchical_visitor.cpp')
-rw-r--r--src/glsl/ir_hierarchical_visitor.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/glsl/ir_hierarchical_visitor.cpp b/src/glsl/ir_hierarchical_visitor.cpp
index 9afb12a4a2b..d475df62fce 100644
--- a/src/glsl/ir_hierarchical_visitor.cpp
+++ b/src/glsl/ir_hierarchical_visitor.cpp
@@ -277,12 +277,7 @@ ir_hierarchical_visitor::visit_leave(ir_if *ir)
void
ir_hierarchical_visitor::run(exec_list *instructions)
{
- foreach_list(n, instructions) {
- ir_instruction *ir = (ir_instruction *) n;
-
- if (ir->accept(this) != visit_continue)
- break;
- }
+ visit_list_elements(this, instructions);
}