irgmod: Pass the new inputs to turn_into_tuple() instead of initialising them with...
[libfirm] / ir / be / beirgmod.c
index 34b221b..bf6506c 100644 (file)
@@ -51,7 +51,7 @@
 #include "irgraph_t.h"
 #include "irgopt.h"
 #include "irgmod.h"
-#include "irprintf_t.h"
+#include "irprintf.h"
 #include "irgwalk.h"
 
 #include "be_t.h"
@@ -99,7 +99,7 @@ ir_node *insert_Perm_before(ir_graph *irg, const arch_register_class_t *cls,
        DBG((dbg, LEVEL_1, "Insert Perm before: %+F\n", pos));
 
        ir_nodeset_init(&live);
-       be_liveness_nodes_live_at(lv, cls, sched_prev(pos), &live);
+       be_liveness_nodes_live_before(lv, cls, pos, &live);
 
        n = ir_nodeset_size(&live);
        if (n == 0) {
@@ -127,12 +127,10 @@ ir_node *insert_Perm_before(ir_graph *irg, const arch_register_class_t *cls,
 
        for (i = 0; i < n; ++i) {
                ir_node *perm_op = get_irn_n(perm, i);
-               const arch_register_t *reg = arch_get_irn_register(perm_op);
                be_ssa_construction_env_t senv;
 
                ir_mode *mode = get_irn_mode(perm_op);
                ir_node *proj = new_r_Proj(perm, mode, i);
-               arch_set_irn_register(proj, reg);
 
                be_ssa_construction_init(&senv, irg);
                be_ssa_construction_add_copy(&senv, perm_op);