Prevent beuses from choking on basic blocks without control flow successors.
authorChristoph Mallon <christoph.mallon@gmx.de>
Thu, 11 Sep 2008 10:18:22 +0000 (10:18 +0000)
committerChristoph Mallon <christoph.mallon@gmx.de>
Thu, 11 Sep 2008 10:18:22 +0000 (10:18 +0000)
[r21837]

ir/be/beuses.c

index b3261d3..dcef874 100644 (file)
@@ -126,10 +126,12 @@ static int be_is_phi_argument(const ir_node *block, const ir_node *def)
        const ir_edge_t *edge;
        int arity, i;
 
-#if 0
-       if(get_irn_n_edges_kind(block, EDGE_KIND_BLOCK) > 1)
-               return 0;
+#if 1
+       if (get_irn_n_edges_kind(block, EDGE_KIND_BLOCK) < 1)
+#else
+       if (get_irn_n_edges_kind(block, EDGE_KIND_BLOCK) != 1)
 #endif
+               return 0;
 
        foreach_block_succ(block, edge) {
                succ_block = get_edge_src_irn(edge);