Mesa (master): nir: Correctly handle blocks in cf_node_cf_tree_next

Jason Ekstrand jekstrand at kemper.freedesktop.org
Fri Dec 23 01:17:05 UTC 2016


Module: Mesa
Branch: master
Commit: 993e9195d42763d43f9f7453f77ac5b667f799e3
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=993e9195d42763d43f9f7453f77ac5b667f799e3

Author: Jason Ekstrand <jason.ekstrand at intel.com>
Date:   Mon Dec 19 10:46:04 2016 -0800

nir: Correctly handle blocks in cf_node_cf_tree_next

Reviewed-by: Timothy Arceri <timothy.arceri at collabora.com>

---

 src/compiler/nir/nir.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/compiler/nir/nir.c b/src/compiler/nir/nir.c
index 2c3531c..885616e 100644
--- a/src/compiler/nir/nir.c
+++ b/src/compiler/nir/nir.c
@@ -1753,7 +1753,7 @@ nir_block *nir_cf_node_cf_tree_last(nir_cf_node *node)
 nir_block *nir_cf_node_cf_tree_next(nir_cf_node *node)
 {
    if (node->type == nir_cf_node_block)
-      return nir_cf_node_cf_tree_first(nir_cf_node_next(node));
+      return nir_block_cf_tree_next(nir_cf_node_as_block(node));
    else if (node->type == nir_cf_node_function)
       return NULL;
    else




More information about the mesa-commit mailing list