History log of /external/mesa3d/src/glsl/ir_builder.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
d9da350a8334201400a43d105b92fce2bd6a5f32 10-Jul-2012 Kenneth Graunke <kenneth@whitecape.org> glsl/ir_builder: Add a new swizzle_for_size() function.

This swizzles away unwanted components, while preserving the order of
the ones that remain.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
/external/mesa3d/src/glsl/ir_builder.h
0bb3d4ba54f98f4d45abe598dabc905f08055cd5 09-Jul-2012 Kenneth Graunke <kenneth@whitecape.org> glsl/ir_builder: Add a generic constructor for unary expressions.

I needed to compute logs and square roots in a patch I was working on,
and wanted to use the convenient interface. We already have a similar
constructor for binops; adding one for unops seems reasonable.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
/external/mesa3d/src/glsl/ir_builder.h
8bb0091e6838aeee2a5819850c334fde71b5a439 20-Mar-2012 Eric Anholt <eric@anholt.net> glsl: Add a helper for generating temporary variables in ir_builder.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
/external/mesa3d/src/glsl/ir_builder.h
d32780d5041a6d241834fe565739104f86300425 20-Mar-2012 Eric Anholt <eric@anholt.net> glsl: Add a helper for ir_builder to make dereferences for assignments.

v2: Fix writemask setup for non-vec4 assignments.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
/external/mesa3d/src/glsl/ir_builder.h
7e88f8ce8f9d72bbda248554e0630b4aca7e1154 20-Mar-2012 Eric Anholt <eric@anholt.net> 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 <kenneth@whitecape.org>
/external/mesa3d/src/glsl/ir_builder.h
b782352745d322596a9122969f5c0e57ea032c1b 19-Mar-2012 Eric Anholt <eric@anholt.net> glsl: Add common swizzles to ir_builder.

Now we can fold a bunch of our expression setup in ff_fragment_shader
into single-line, parseable commits.

v2: Make it actually work. I wasn't setting num_components in the
mask structure, and not setting up a mask structure is way easier.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
/external/mesa3d/src/glsl/ir_builder.h
d6e6566206029ace72ba037a3ef7950876eeb88b 19-Mar-2012 Eric Anholt <eric@anholt.net> glsl: Let ir_builder expressions take un-dereferenced variables.

Having to explicitly dereference is irritating and bloats the code,
when the compiler can detect and do the right thing.

v2: Use a little shim class to produce the automatic dereference
generation at compile time as opposed to runtime, while also
allowing compile-time type checking.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
/external/mesa3d/src/glsl/ir_builder.h
599aac95ff2149d881177ed75a48d97d3dcf47bd 19-Mar-2012 Eric Anholt <eric@anholt.net> glsl: Create an ir_builder helper for hand-generating IR.

The C++ constructors with placement new, while functional, are
extremely verbose, leading to generation of simple GLSL IR expressions
like (a * b + c * d) expanding to many lines of code and using lots of
temporary variables. By creating a new ir_builder.h that puts simple
generators in our namespace and taking advantage of ralloc_parent(),
we can generate much more compact code, at a minor runtime cost.

v2: Replace ir_instruction usage with just ir_rvalue.
v3: Drop remaining missed as_rvalue() in v2.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
/external/mesa3d/src/glsl/ir_builder.h