nir: Add a phi node placement helper
authorJason Ekstrand <jason.ekstrand@intel.com>
Sat, 13 Feb 2016 05:41:42 +0000 (21:41 -0800)
committerJason Ekstrand <jason.ekstrand@intel.com>
Thu, 24 Mar 2016 22:20:44 +0000 (15:20 -0700)
commite4dc82cfcffd9c3472b962b6bd7328788926452d
treebe59a0c6768f23386566f6b5b3e6109eaf9dddef
parent9a41d947319f2d2999b4b5442ce20443d7c3cf3a
nir: Add a phi node placement helper

Right now, we have phi placement code in two places and there are other
places where it would be nice to be able to do this analysis.  Instead of
repeating it all over the place, this commit adds a helper for placing all
of the needed phi nodes for a value.

v2: Add better documentation

Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
src/compiler/Makefile.sources
src/compiler/nir/Makefile.sources
src/compiler/nir/nir_phi_builder.c [new file with mode: 0644]
src/compiler/nir/nir_phi_builder.h [new file with mode: 0644]