- moved peephole_IncSP_IncSP() to bepeephole.c, as this is a generic function and...
[libfirm] / ir / be / becopyilp2.c
index ad41740..7208ae6 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 1995-2007 University of Karlsruhe.  All right reserved.
+ * Copyright (C) 1995-2008 University of Karlsruhe.  All right reserved.
  *
  * This file is part of libFirm.
  *
@@ -291,19 +291,24 @@ static void build_clique_star_cstr(ilp_env_t *ienv) {
        co_gs_foreach_aff_node(ienv->co, aff) {
                struct obstack ob;
                neighb_t *nbr;
-               ir_node *center = aff->irn;
+               const ir_node *center = aff->irn;
                ir_node **nodes;
                set *edges;
                int i, o, n_nodes, n_edges;
 
+               if (arch_irn_is(ienv->co->aenv, aff->irn, ignore))
+                       continue;
+
                obstack_init(&ob);
                edges = new_set(compare_edge_t, 8);
 
                /* get all affinity neighbours */
                n_nodes = 0;
                co_gs_foreach_neighb(aff, nbr) {
-                       obstack_ptr_grow(&ob, nbr->irn);
-                       ++n_nodes;
+                       if (!arch_irn_is(ienv->co->aenv, nbr->irn, ignore)) {
+                               obstack_ptr_grow(&ob, nbr->irn);
+                               ++n_nodes;
+                       }
                }
                nodes = obstack_finish(&ob);
 
@@ -393,7 +398,7 @@ static void build_clique_star_cstr(ilp_env_t *ienv) {
 }
 
 
-static void extend_path(ilp_env_t *ienv, pdeq *path, ir_node *irn) {
+static void extend_path(ilp_env_t *ienv, pdeq *path, const ir_node *irn) {
        be_ifg_t *ifg = ienv->co->cenv->ifg;
        int i, len;
        ir_node **curr_path;
@@ -404,6 +409,9 @@ static void extend_path(ilp_env_t *ienv, pdeq *path, ir_node *irn) {
        if (pdeq_contains(path, irn))
                return;
 
+       if (arch_irn_is(ienv->co->aenv, irn, ignore))
+               return;
+
        /* insert the new irn */
        pdeq_putr(path, irn);