2 ** Copyright (C) 2001 by Universitaet Karlsruhe
3 ** All rights reserved.
5 ** Authors: Goetz Lindenmaier
7 ** debinfo: This is the Firm interface to debugging support. Firm requires
8 ** a debugging module fulfilling this interface.
9 ** The interface requires a datatype representing the debugging information.
10 ** Firm supports administrating a reference to the debug information
11 ** in every firm node. Further Firm optimizations call routines to
12 ** propagate debug information from old nodes to new nodes if the optimization
13 ** replaces the old ones by the new ones.
15 ** This file does not belong to the interface of the firm library.
26 /* A datastructure containing information for debugging. */
27 typedef struct deb_info deb_info;
28 /* Every Firm node contains a reference to a deb_info struct. This reference
29 can be accessed by the debug support module by
30 deb_info *get_irn_deb_info(irnode *n);
31 void set_irn_deb_info(irnode *n, deb_info *d);.
32 The module may not touch or change anything else in the Firm data structure.
35 /** The following routines are called by firm optmizations. The optimization
36 passes an ident representing a string that describes the optimization
38 /* deb_info_copy() is called in the following situation:
39 The optimization replaced the old node by the new one. The new node
40 might be a recent allocated node not containing any debug information,
41 or just another node from somewhere in the graph with the same
43 void deb_info_copy(ir_node *new, ir_node *old, ident *info);
45 /* deb_info_merge() is called in the following situation:
46 The optimization replaced a subgraph by another subgraph. There is no
47 obviouse mapping between single nodes in both subgraphs. The optimization
48 simply passes two lists to the debug module, one containing the nodes in
49 the old subgraph, the other containing the nodes in the new subgraph. */
50 void deb_info_merge(ir_node **new_nodes, ir_node **old_nodes, ident *info);
53 #endif /* _DEBINFO_H_ */