bepeephole: Inline be_peephole_new_node() into its only caller.
authorChristoph Mallon <christoph.mallon@gmx.de>
Fri, 14 Dec 2012 22:08:22 +0000 (23:08 +0100)
committerChristoph Mallon <christoph.mallon@gmx.de>
Sat, 15 Dec 2012 21:03:44 +0000 (22:03 +0100)
ir/be/bepeephole.c
ir/be/bepeephole.h

index d048af2..6ff06f5 100644 (file)
@@ -96,11 +96,6 @@ static void set_uses(ir_node *node)
        }
 }
 
-void be_peephole_new_node(ir_node * nw)
-{
-       be_liveness_introduce(lv, nw);
-}
-
 /**
  * must be called from peephole optimisations before a node will be killed
  * and its users will be redirected to new_node.
@@ -157,7 +152,7 @@ void be_peephole_exchange(ir_node *old, ir_node *nw)
        be_peephole_before_exchange(old, nw);
        sched_remove(old);
        exchange(old, nw);
-       be_peephole_new_node(nw);
+       be_liveness_introduce(lv, nw);
 }
 
 /**
index a008cdd..26a53c3 100644 (file)
@@ -31,18 +31,11 @@ static inline ir_node *be_peephole_get_reg_value(const arch_register_t *reg)
  */
 typedef void (*peephole_opt_func) (ir_node *node);
 
-/**
- * Notify the peephole phase about a newly added node, so it can update its
- * internal state.  This is not needed for the new node, when
- * be_peephole_exchange() is used.
- * Note: Contrary to normal exchange you mustn't remove the node from the
- * schedule either before exchange. Exchange will do that for you.
- */
-void be_peephole_new_node(ir_node *nw);
-
 /**
  * When doing peephole optimisation use this function instead of plain
- * exchange(), so it can update its internal state. */
+ * exchange(), so it can update its internal state.  This function also removes
+ * the old node from the schedule.
+ */
 void be_peephole_exchange(ir_node *old, ir_node *nw);
 
 /**