# ifndef _IRGRAPH_H_
# define _IRGRAPH_H_
-# include "tv.h"
# include "entity.h"
/* to resolve recursion between irnode.h and irgraph.h */
phase_low
} irg_phase_state;
+/** returns the phase_state of an IR graph. */
irg_phase_state get_irg_phase_state (const ir_graph *irg);
+
+/** sets the phase state of an IR graph. */
void set_irg_phase_low(ir_graph *irg);
/** state: op_pin_state_pinned
op_pin_state get_irg_pinned (const ir_graph *irg);
/** state: outs_state
- Outs are the back edges or def-use edges.
- Values: outs_none, outs_consistent, outs_inconsistent
- outs_none: outs are not computed, no memory is allocated.
- outs_consistent: outs are computed and correct,
- outs_inconsistent: outs have been computed, memory is still allocated,
- but the graph has been changed since. */
+ * Outs are the back edges or def-use edges of ir nodes.
+ * Values: outs_none, outs_consistent, outs_inconsistent */
typedef enum {
- outs_none,
- outs_consistent,
- outs_inconsistent
+ outs_none, /**< Outs are not computed, no memory is allocated. */
+ outs_consistent, /**< Outs are computed and correct. */
+ outs_inconsistent /**< Outs have been computed, memory is still allocated,
+ but the graph has been changed since. */
} irg_outs_state;
irg_outs_state get_irg_outs_state(const ir_graph *irg);
-void set_irg_outs_inconsistent(ir_graph *irg);
+void set_irg_outs_inconsistent(ir_graph *irg);
/** state: dom_state
Signals the state of the dominator infomation.
dom_consistent, /**< dominator information is computed and correct */
dom_inconsistent /**< dominator information is computed but the graph has been changed since */
} irg_dom_state;
+
+/** returns the dom_state of an IR graph. */
irg_dom_state get_irg_dom_state(const ir_graph *irg);
+
+/** sets the dom_state of an IR graph. */
void set_irg_dom_inconsistent(ir_graph *irg);
/** state: loopinfo_state
irg_callee_info_consistent,
irg_callee_info_inconsistent
} irg_callee_info_state;
+
+/** returns the callee_info_state of an IR graph. */
irg_callee_info_state get_irg_callee_info_state(const ir_graph *irg);
+
+/** sets the callee_info_state of an IR graph. */
void set_irg_callee_info_state(ir_graph *irg, irg_callee_info_state s);
/** property:
/** Sets the inline property of a graph. */
void set_irg_inline_property(ir_graph *irg, irg_inline_property s);
-/** A void * field to link arbritary information to the node. */
+/** A void * field to link arbitrary information to the node. */
void set_irg_link (ir_graph *irg, void *thing);
void *get_irg_link (const ir_graph *irg);
-/* increments visited by one */
+/** Increments visited flag by one.
+ * @see also: get_irn_visited() get_irg_block_visited(). */
void inc_irg_visited (ir_graph *irg);
unsigned long get_irg_visited (const ir_graph *irg);
void set_irg_visited (ir_graph *irg, unsigned long i);
+/** An interprocedural flag valid for all irgs.
+ * @see also: get_irn_visited() get_irg_block_visited(). */
unsigned long get_max_irg_visited (void);
void set_max_irg_visited (int val);
unsigned long inc_max_irg_visited (void);
-/* increments block_visited by one */
+/** Increments block_visited by one.
+ * @see also: get_irn_visited() get_irg_block_visited(). */
void inc_irg_block_visited (ir_graph *irg);
unsigned long get_irg_block_visited (const ir_graph *irg);
void set_irg_block_visited (ir_graph *irg, unsigned long i);
-/** put the proj's into the same block as its predecessors */
+/** move Proj nodes into the same block as its predecessors */
void normalize_proj_nodes(ir_graph *irg);
+/** set a description for local value n */
+void set_irg_loc_description(ir_graph *irg, int n, void *description);
+
+/** get the description for local value n */
+void *get_irg_loc_description(ir_graph *irg, int n);
+
/**
* Access custom graph data.
* The data must have been registered with