BugFix: in newer Firm, keep-alives may be other than Block & Phi
[libfirm] / ir / ir / irnode.c
index 2a0ba2e..44e3ff1 100644 (file)
@@ -30,6 +30,7 @@
 #include "iredges_t.h"
 
 #include "irhooks.h"
+#include "irtools.h"
 
 /* some constants fixing the positions of nodes predecessors
    in the in array */
 #define END_KEEPALIVE_OFFSET  0
 
 static const char *pnc_name_arr [] = {
-  "False", "Eq", "Lt", "Le",
-  "Gt", "Ge", "Lg", "Leg", "Uo",
-  "Ue", "Ul", "Ule", "Ug", "Uge",
-  "Ne", "True"
+  "pn_Cmp_False", "pn_Cmp_Eq", "pn_Cmp_Lt", "pn_Cmp_Le",
+  "pn_Cmp_Gt", "pn_Cmp_Ge", "pn_Cmp_Lg", "pn_Cmp_Leg",
+  "pn_Cmp_Uo", "pn_Cmp_Ue", "pn_Cmp_Ul", "pn_Cmp_Ule",
+  "pn_Cmp_Ug", "pn_Cmp_Uge", "pn_Cmp_Ne", "pn_Cmp_True"
 };
 
 /**
@@ -465,13 +466,12 @@ void firm_set_irn_section(ir_node *n, struct section *s) {}
 
 
 /* Outputs a unique number for this node */
-long
-get_irn_node_nr(const ir_node *node) {
+long get_irn_node_nr(const ir_node *node) {
   assert(node);
 #ifdef DEBUG_libfirm
   return node->node_nr;
 #else
-  return (long)node;
+  return (long)PTR_TO_INT(node);
 #endif
 }