projects
/
libfirm
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add an get_irg_idx
[libfirm]
/
ir
/
ir
/
irgraph.c
diff --git
a/ir/ir/irgraph.c
b/ir/ir/irgraph.c
index
103a763
..
c20c61f
100644
(file)
--- a/
ir/ir/irgraph.c
+++ b/
ir/ir/irgraph.c
@@
-413,14
+413,15
@@
int
return _is_ir_graph(thing);
}
return _is_ir_graph(thing);
}
-/* Outputs a unique number for this node */
-long get_irg_graph_nr(ir_graph *irg) {
- assert(irg);
#ifdef DEBUG_libfirm
#ifdef DEBUG_libfirm
+/* Outputs a unique number for this node */
+long get_irg_graph_nr(const ir_graph *irg) {
return irg->graph_nr;
return irg->graph_nr;
-#else
- return (long)PTR_TO_INT(irg);
+}
#endif
#endif
+
+int get_irg_idx(const ir_graph *irg) {
+ return irg->index;
}
ir_node *
}
ir_node *