summaryrefslogtreecommitdiff
path: root/ir_expression_flattening.cpp
AgeCommit message (Collapse)Author
2010-06-23exec_node: Add new talloc-based new()Carl Worth
And fix all callers to use the tallbac-based new for exec_node construction. We make ready use of talloc_parent in order to get valid, (and appropriate) talloc owners for everything we construct without having to add new 'ctx' parameters up and down all the call trees. This closes the majority of the memory leaks in the glsl-orangebook-ch06-bump.frag test: total heap usage: 55,623 allocs, 42,672 frees (was 14,533 frees) Now 76.7% leak-free. Woo-hoo!
2010-06-22Include stdio.h and stdlib.h everywhere, and don't cook our own #define NULL.Eric Anholt
2010-06-01ir_expression_flattening: Handle flattening values out of swizzles, too.Eric Anholt
Fixes an uninlined normalize() in CorrectSwizzle2.vert.
2010-06-01ir_expression_flattening: Fix breakage from hierarchichal visitor.Eric Anholt
Similar to other situations where the visitor pattern doesn't fit, in this case we need the pointer to the base instruction in the instruction stream for where to insert any new instructions we generate (not the instruction in the tree we're looking at). By removing the code for setting the base_ir, flattened expressions would end up, for example, before the function definition where they had appeared.
2010-05-26Reimplement ir_expression_flattening_visitor using ir_hierarchical_vistorIan Romanick
2010-05-26Refactor ir_dereference data fields to subclassesIan Romanick
2010-05-26Refactor ir_dereference support for ir_visitorIan Romanick
Move the accept method for visitors from ir_dereference to the derived classes.
2010-05-26Begin refactoring ir_dereferenceIan Romanick
Create separate subclasses of ir_dereference for variable, array, and record dereferences. As a side effect, array and record dereferences no longer point to ir_variable objects directly. Instead they each point to an ir_dereference_variable object. This is the first of several steps in the refactoring process. The intention is that ir_dereference will eventually become an abstract base class.
2010-04-21Remove ir_label since it is no longer used.Kenneth Graunke
2010-04-16Add support for inlining calls done inside of expressions.Eric Anholt