glsl2: Add constant propagation.
authorEric Anholt <eric@anholt.net>
Tue, 10 Aug 2010 00:03:46 +0000 (17:03 -0700)
committerEric Anholt <eric@anholt.net>
Tue, 10 Aug 2010 02:21:18 +0000 (19:21 -0700)
commit8bebbeb7c5b26ec9166a4644a2c051238d18509b
treef2f663f93e10674b2e39f3c1a44a0e8a57060b1b
parent81996ae8618759cf7fdd033042a96f3014659f6c
glsl2: Add constant propagation.

Whereas constant folding evaluates constant expressions at rvalue
nodes, constant propagation tracks constant components of vectors
across execution to replace (possibly swizzled) variable dereferences
with constant values, triggering possible constant folding or reduced
variable liveness.
src/glsl/Makefile
src/glsl/ir_constant_propagation.cpp [new file with mode: 0644]
src/glsl/ir_optimization.h
src/glsl/linker.cpp
src/glsl/main.cpp
src/mesa/program/ir_to_mesa.cpp