diff options
author | Eric Anholt <[email protected]> | 2012-03-19 16:01:52 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2012-04-13 17:01:14 -0700 |
commit | 7e88f8ce8f9d72bbda248554e0630b4aca7e1154 (patch) | |
tree | b5826b0f173c1df998b0eb077392d9bad56f0ccf /src/glsl/ir_builder.cpp | |
parent | b782352745d322596a9122969f5c0e57ea032c1b (diff) |
glsl: Make a little tracking class for emitting IR lists.
This lets us significantly shorten p->instructions->push_tail(ir), and
will be used in a few more places.
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/glsl/ir_builder.cpp')
-rw-r--r-- | src/glsl/ir_builder.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/glsl/ir_builder.cpp b/src/glsl/ir_builder.cpp index 29cc9bc851f..98ac3c100a1 100644 --- a/src/glsl/ir_builder.cpp +++ b/src/glsl/ir_builder.cpp @@ -28,6 +28,12 @@ using namespace ir_builder; namespace ir_builder { +void +ir_factory::emit(ir_instruction *ir) +{ + instructions->push_tail(ir); +} + ir_swizzle * swizzle(operand a, int swizzle, int components) { |