On Thu, May 21, 2015 at 9:40 AM, Connor Abbott <cwabbo...@gmail.com> wrote:
> Before, we might have left dangling predecessors from jumps that were
> going to be removed.
>
> v2: split out from "nir: insert ssa_undef instructions when cleaning up
>     defs/uses"
>
> Signed-off-by: Connor Abbott <cwabbo...@gmail.com>
> ---
>  src/glsl/nir/nir.c | 10 ++++++++--
>  1 file changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c
> index a2b5e7c..dc6d63f 100644
> --- a/src/glsl/nir/nir.c
> +++ b/src/glsl/nir/nir.c
> @@ -1214,9 +1214,15 @@ cleanup_cf_node(nir_cf_node *node, nir_function_impl 
> *impl)
>     switch (node->type) {
>     case nir_cf_node_block: {
>        nir_block *block = nir_cf_node_as_block(node);
> -      /* We need to walk the instructions and clean up defs/uses */
> -      nir_foreach_instr(block, instr)
> +      /* We need to walk the instructions and clean up defs/uses,
> +       * as well as clean up any jumps to control flow that may not be 
> getting
> +       * deleted.

I think you can line wrap this block a little better.
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to