summaryrefslogtreecommitdiffstats
path: root/src/compiler/nir/nir_dominance.c
Commit message (Collapse)AuthorAgeFilesLines
* nir: Switch the arguments to nir_foreach_functionJason Ekstrand2016-04-281-4/+4
| | | | | | | | | This matches the "foreach x in container" pattern found in many other programming languages. Generated by the following regular expression: s/nir_foreach_function(\([^,]*\),\s*\([^,]*\))/nir_foreach_function(\2, \1)/ Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
* nir/dominance: fixup for new foreach_block()Connor Abbott2016-04-281-101/+59
| | | | Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
* nir: rename nir_foreach_block*() to nir_foreach_block*_call()Connor Abbott2016-04-201-9/+9
| | | | Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
* nir/dominance: Handle unreachable blocksJason Ekstrand2016-03-241-1/+5
| | | | | | | | | | | | | | | | | | | | | Previously, nir_dominance.c didn't properly handle unreachable blocks. This can happen if, for instance, you have something like this: loop { if (...) { break; } else { break; } } In this case, the block right after the if statement will be unreachable. This commit makes two changes to handle this. First, it removes an assert and allows block->imm_dom to be null if the block is unreachable. Second, it properly skips unreachable blocks in calc_dom_frontier_cb. Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
* nir: move to compiler/Emil Velikov2016-01-261-0/+350
Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Acked-by: Matt Turner <mattst88@gmail.com> Acked-by: Jose Fonseca <jfonseca@vmware.com>