X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fir%2Firedges_t.h;h=c2b291b5e137c5a457f7f316c11734d56ec2e541;hb=0f234e2d94155d13c0e4727871125beda0eaa66d;hp=ced4650377237250cce68910efa11e662c409440;hpb=bb9f2e36362333c6635b89f5258171b06c786608;p=libfirm diff --git a/ir/ir/iredges_t.h b/ir/ir/iredges_t.h index ced465037..c2b291b5e 100644 --- a/ir/ir/iredges_t.h +++ b/ir/ir/iredges_t.h @@ -44,15 +44,15 @@ * An edge. */ struct _ir_edge_t { - ir_node *src; /**< The source node of the edge. */ - int pos; /**< The position of the edge at @p src. */ - unsigned invalid : 1; /**< edges that are removed are marked invalid. */ - unsigned present : 1; /**< Used by the verifier. Don't rely on its content. */ - unsigned kind : 4; /**< The kind of the edge. */ - struct list_head list; /**< The list head to queue all out edges at a node. */ + ir_node *src; /**< The source node of the edge. */ + int pos; /**< The position of the edge at @p src. */ + unsigned invalid : 1; /**< edges that are removed are marked invalid. */ + unsigned present : 1; /**< Used by the verifier. Don't rely on its content. */ + unsigned kind : 4; /**< The kind of the edge. */ + struct list_head list; /**< The list head to queue all out edges at a node. */ #ifdef DEBUG_libfirm - long src_nr; /**< The node number of the source node. */ - long edge_nr; /**< A unique number identifying the edge. */ + long src_nr; /**< The node number of the source node. */ + long edge_nr; /**< A unique number identifying the edge. */ #endif }; @@ -78,7 +78,9 @@ struct _ir_edge_t { */ static inline const ir_edge_t *_get_irn_out_edge_first_kind(const ir_node *irn, ir_edge_kind_t kind) { - const struct list_head *head = _get_irn_outs_head(irn, kind); + const struct list_head *head; + assert(edges_activated_kind(get_irn_irg(irn), kind)); + head = _get_irn_outs_head(irn, kind); return list_empty(head) ? NULL : list_entry(head->next, ir_edge_t, list); } @@ -141,6 +143,11 @@ void edges_notify_edge_kind(ir_node *src, int pos, ir_node *tgt, ir_node *old_tg */ void edges_node_deleted(ir_node *old, ir_graph *irg); +/** + * A node might be revivaled by CSE. + */ +void edges_node_revival(ir_node *node, ir_graph *irg); + void edges_invalidate_kind(ir_node *irn, ir_edge_kind_t kind, ir_graph *irg); /**