+#if PRECISE_EXC_CONTEXT
+ irg->n_loc = n_loc + 1 + 1;
+#else
+ irg->n_loc = n_loc + 1;
+#endif
+}
+
+
+
+/* Returns the obstack associated with the graph. */
+struct obstack *get_irg_obstack(ir_graph *irg) {
+ return irg->obst;
+}
+
+/*
+ * Returns true if the node n is allocated on the storage of graph irg.
+ *
+ * Implementation is GLIBC specific as is uses the internal _obstack_chunk implementation.
+ */
+int node_is_in_irgs_storage(ir_graph *irg, ir_node *n)
+{
+ struct _obstack_chunk *p;
+
+ /*
+ * checks wheater the ir_node pointer i on the obstack.
+ * A more sophisticated check would test the "whole" ir_node
+ */
+ for (p = irg->obst->chunk; p; p = p->prev) {
+ if (((char *)p->contents <= (char *)n) && ((char *)n < (char *)p->limit))
+ return 1;
+ }
+
+ return 0;
+}
+
+irg_phase_state
+get_irg_phase_state (ir_graph *irg) {
+ return irg->phase_state;
+}
+
+void
+set_irg_phase_low(ir_graph *irg) {
+ irg->phase_state = phase_low;
+}
+
+op_pinned
+get_irg_pinned (ir_graph *irg) {
+ return irg->pinned;
+}
+
+irg_outs_state
+get_irg_outs_state(ir_graph *irg) {
+ return irg->outs_state;
+}
+
+void
+set_irg_outs_inconsistent(ir_graph *irg) {
+ irg->outs_state = outs_inconsistent;
+}
+
+irg_dom_state
+get_irg_dom_state(ir_graph *irg) {
+ return irg->dom_state;
+}
+
+void
+set_irg_dom_inconsistent(ir_graph *irg) {
+ irg->dom_state = dom_inconsistent;
+}
+
+irg_loopinfo_state
+get_irg_loopinfo_state(ir_graph *irg) {
+ return irg->loopinfo_state;
+}
+
+void set_irg_loopinfo_state(ir_graph *irg, irg_loopinfo_state s) {
+ irg->loopinfo_state = s;
+}
+
+void
+set_irg_loopinfo_inconsistent(ir_graph *irg) {
+ if (irg->loopinfo_state == loopinfo_ip_consistent)
+ irg->loopinfo_state = loopinfo_ip_inconsistent;
+ else
+ irg->loopinfo_state = loopinfo_inconsistent;
+}
+
+INLINE void
+set_irg_pinned (ir_graph *irg, op_pinned p) {
+ irg->pinned = p;