X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fbe%2Fbeutil.c;h=6e6abf2bba4bfe8c10a9d1a1bb67d437507588d5;hb=51d8477e3b9f11aa3d8f38ef386ab46a63b26a0b;hp=66cf3d8b9aec00ca829503977dd41af042cca7ab;hpb=32ea6ea0320f551448bb66e534e3351977464d42;p=libfirm diff --git a/ir/be/beutil.c b/ir/be/beutil.c index 66cf3d8b9..6e6abf2bb 100644 --- a/ir/be/beutil.c +++ b/ir/be/beutil.c @@ -38,7 +38,7 @@ #include "irgopt.h" #include "irtools.h" #include "irprintf.h" -#include "iredges.h" +#include "iredges_t.h" #include "beutil.h" #include "besched.h" @@ -49,7 +49,7 @@ pset *be_empty_set(void) { static pset *empty_set = NULL; - if(!empty_set) + if (!empty_set) empty_set = pset_new_ptr(1); assert(pset_count(empty_set) == 0); @@ -191,3 +191,10 @@ ir_node **be_get_cfgpostorder(ir_graph *irg) return list; } + +ir_node *get_first_block_succ(const ir_node *block) +{ + const ir_edge_t *edge = get_irn_out_edge_first_kind(block, EDGE_KIND_BLOCK); + assert(edge != NULL); + return get_edge_src_irn(edge); +}