make unique types/entities part of irprog
[libfirm] / ir / be / beflags.c
index 4d010dd..52027ec 100644 (file)
@@ -21,7 +21,6 @@
  * @file
  * @brief       modifies schedule so flags dependencies are respected.
  * @author      Matthias Braun, Christoph Mallon
- * @version     $Id: besched.h 14693 2007-06-21 15:35:49Z beck $
  *
  * Fixup schedule to respect flag constraints by moving and rematerialisation of
  * nodes.
@@ -54,6 +53,7 @@
 #include "besched.h"
 #include "benode.h"
 #include "belive.h"
+#include "beabihelper.h"
 
 static const arch_register_class_t *flag_class;
 static const arch_register_t       *flags_reg;
@@ -161,6 +161,7 @@ static void rematerialize_or_move(ir_node *flags_needed, ir_node *node,
        if (get_irn_mode(copy) == mode_T) {
                ir_mode *mode = flag_class->mode;
                value = new_rd_Proj(NULL, copy, mode, pn);
+               be_add_missing_keeps_node(copy);
        } else {
                value = copy;
        }