arch_set_irn_register(res1, cycle.elems[i]);
/* insert the copy/exchange node in schedule after the magic schedule node (see above) */
- sched_add_after(skip_Proj(sched_point), cpyxchg);
+ sched_add_after(sched_point, cpyxchg);
DB((dbg, LEVEL_1, "replacing %+F with %+F, placed new node after %+F\n", irn, cpyxchg, sched_point));
/* set the new scheduling point */
- sched_point = res1;
+ sched_point = cpyxchg;
} else {
ir_node *cpyxchg;
exchange(res2, cpyxchg);
/* insert the copy/exchange node in schedule after the magic schedule node (see above) */
- sched_add_after(skip_Proj(sched_point), cpyxchg);
+ sched_add_after(sched_point, cpyxchg);
/* set the new scheduling point */
sched_point = cpyxchg;