X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fbe%2Fbeflags.c;h=cb1e068b2b7083d0be66986431aaa997ce94282b;hb=41658443cdd74a5ce93c986ab9e623cc92d11f38;hp=19af144dd46f6ba6f682722f64c7f7d03d2640e3;hpb=fcb579b8959da1d7563b1a7b9f008a423ffdf75a;p=libfirm diff --git a/ir/be/beflags.c b/ir/be/beflags.c index 19af144dd..cb1e068b2 100644 --- a/ir/be/beflags.c +++ b/ir/be/beflags.c @@ -35,9 +35,7 @@ * spilled. So in some situations (for example 2 adc-nodes that use the flags of * a single add node on x86) operations have to be repeated to work correctly. */ -#ifdef HAVE_CONFIG_H #include "config.h" -#endif #include "irgwalk.h" #include "irnode_t.h" @@ -74,7 +72,7 @@ static ir_node *default_remat(ir_node *node, ir_node *after) } /** - * tests wether we can legally move node node after node after + * tests whether we can legally move node node after node after * (only works for nodes in same block) */ static int can_move(ir_node *node, ir_node *after) @@ -93,15 +91,15 @@ static int can_move(ir_node *node, ir_node *after) assert(get_irn_n_edges_kind(out, EDGE_KIND_DEP) == 0); foreach_out_edge(out, edge2) { ir_node *out2 = get_edge_src_irn(edge2); - /* phi represents a usage at block end */ - if(is_Phi(out2)) + /* Phi or End represents a usage at block end. */ + if(is_Phi(out2) || is_End(out2)) continue; if(is_Sync(out2)) { const ir_edge_t *edge3; foreach_out_edge(out2, edge3) { ir_node *out3 = get_edge_src_irn(edge3); - /* phi represents a usage at block end */ - if(is_Phi(out3)) + /* Phi or End represents a usage at block end. */ + if(is_Phi(out3) || is_End(out3)) continue; assert(!is_Sync(out3)); if(sched_get_time_step(out3) <= sched_get_time_step(after)) {