Added sparse matrix impl. Used by copyopt_ilp
[libfirm] / ir / be / bechordal_t.h
1
2 /**
3  * Internal datastructures for the chordal register allocator.
4  * @author Sebastian Hack
5  * @date 25.1.2005
6  */
7
8 #ifndef _BECHORDAL_T_H
9 #define _BECHORDAL_T_H
10
11 #define BUILD_GRAPH
12
13 /**
14  * A liveness interval border.
15  */
16 typedef struct _border_t {
17 #ifdef DEBUG_libfirm
18         unsigned magic;                                                         /**< A magic number for checking. */
19 #endif
20         struct list_head list;                          /**< list head for queuing. */
21         struct _border_t *other_end;    /**< The other end of the border. */
22         const ir_node *irn;                                             /**< The node. */
23         unsigned step;                                                          /**< The number equal to the interval border. */
24         unsigned pressure;                                              /**< The pressure at this interval border.
25                                                                                                                                         (The border itself is counting). */
26         unsigned is_def : 1;                                    /**< Does this border denote a use or a def. */
27         unsigned is_real : 1;                                   /**< Is the def/use real? Or is it just inserted
28                                                                                                                                         at block beginnings or ends to ensure that inside
29                                                                                                                                         a block, each value has one begin and one end. */
30 } border_t;
31
32 #ifdef BUILD_GRAPH
33 typedef struct _if_edge_t {
34         int src, tgt;
35 } if_edge_t;
36
37 set *be_ra_get_ifg(ir_graph *irg);
38 #endif
39
40 extern void be_ra_chordal_spill(ir_graph *irg);
41
42 #endif /* _BECHORDAL_T_H */