void edges_activate(ir_graph *irg) {
edges_activate_kind(irg, EDGE_KIND_NORMAL);
edges_activate_kind(irg, EDGE_KIND_BLOCK);
- edges_activate_kind(irg, EDGE_KIND_DEP);
+ if (get_irg_phase_state(irg) == phase_backend)
+ edges_activate_kind(irg, EDGE_KIND_DEP);
}
void edges_deactivate(ir_graph *irg) {
- edges_deactivate_kind(irg, EDGE_KIND_DEP);
+ if (get_irg_phase_state(irg) == phase_backend)
+ edges_deactivate_kind(irg, EDGE_KIND_DEP);
edges_deactivate_kind(irg, EDGE_KIND_BLOCK);
edges_deactivate_kind(irg, EDGE_KIND_NORMAL);
}
assert(edges_activated(current_ir_graph));
assert(is_Block(node));
- set_using_block_visited(current_ir_graph);
+ ir_reserve_resources(current_ir_graph, IR_RESOURCE_BLOCK_VISITED);
inc_irg_block_visited(current_ir_graph);
irg_block_edges_walk2(node, pre, post, env);
- clear_using_block_visited(current_ir_graph);
+ ir_free_resources(current_ir_graph, IR_RESOURCE_BLOCK_VISITED);
}