/*
- * 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.
*
#include <stdio.h>
#include <stdlib.h>
#include <limits.h>
-#include <libcore/lc_opts.h>
-#include <libcore/lc_opts_enum.h>
+#include "lc_opts.h"
+#include "lc_opts_enum.h"
#include "set.h"
#include "pset.h"
/* should_be_equal constraints are affinites */
for (pos = 0, max = get_irn_arity(irn); pos<max; ++pos) {
req = arch_get_register_req(raenv->aenv, irn, pos);
-
if (arch_register_req_is(req, should_be_same)) {
- ir_node *other = get_irn_n(skip_Proj(irn), req->other_same);
- if(arch_irn_is(raenv->aenv, other, ignore)) {
- vi2 = be_get_var_info(other);
+ const int* i;
+ for (i = req->other_same; i != ENDOF(req->other_same); ++i) {
+ ir_node *other;
+
+ if (*i == -1) break;
- fprintf(raenv->f, "(%d, %d, %d)\n", vi1->var_nr, vi2->var_nr, get_affinity_weight(irn));
+ other = get_irn_n(skip_Proj(irn), *i);
+ if(arch_irn_is(raenv->aenv, other, ignore)) {
+ vi2 = be_get_var_info(other);
+ fprintf(raenv->f, "(%d, %d, %d)\n", vi1->var_nr, vi2->var_nr, get_affinity_weight(irn));
+ }
}
}
}
/* Clean up */
free_ssa_destr_simple(raenv.vars);
- be_invalidate_liveness(birg);
+ be_liveness_invalidate(be_get_birg_liveness(birg));
}
/******************************************************************************