nir: Add a pass for propagating invariant decorations
authorJason Ekstrand <jason.ekstrand@intel.com>
Mon, 13 Jun 2016 19:47:19 +0000 (12:47 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Mon, 20 Jun 2016 19:02:45 +0000 (12:02 -0700)
commit202751fbb7e3d35c1aa84f325f862245dab67f6c
tree3a7b17967f2e58e12a7110c9a4c4fd9950a8643c
parent68e308d85355079ad93bd4e16cba164784740fdf
nir: Add a pass for propagating invariant decorations

This pass is similar to propagate_invariance in the GLSL compiler.  The
real "output" of this pass is that any algebraic operations which are
eventually consumed by an invariant variable get marked as "exact".

Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Cc: "12.0" <mesa-stable@lists.freedesktop.org>
src/compiler/Makefile.sources
src/compiler/nir/nir.h
src/compiler/nir/nir_propagate_invariant.c [new file with mode: 0644]