fixed handling of other_same/other_different constraint handling
authorChristian Würdig <chriswue@ipd.info.uni-karlsruhe.de>
Mon, 14 May 2007 15:41:30 +0000 (15:41 +0000)
committerChristian Würdig <chriswue@ipd.info.uni-karlsruhe.de>
Mon, 14 May 2007 15:41:30 +0000 (15:41 +0000)
[r13871]

ir/be/bearch.c
ir/be/beraextern.c

index b5c1fdd..0d12a82 100644 (file)
@@ -329,13 +329,13 @@ extern char *arch_register_req_format(char *buf, size_t len,
        }
 
        if(arch_register_req_is(req, should_be_same)) {
-               const ir_node *same = get_irn_n(node, req->other_same);
+               const ir_node *same = get_irn_n(skip_Proj_const(node), req->other_same);
                ir_snprintf(tmp, sizeof(tmp), " same to: %+F", same);
                strncat(buf, tmp, len);
        }
 
        if(arch_register_req_is(req, should_be_different)) {
-               const ir_node *different = get_irn_n(node, req->other_different);
+               const ir_node *different = get_irn_n(skip_Proj_const(node), req->other_different);
                ir_snprintf(tmp, sizeof(tmp), " different to: %+F", different);
                strncat(buf, tmp, len);
        }
index 0ec86e8..36305a6 100644 (file)
@@ -429,7 +429,7 @@ static void dump_affinities_walker(ir_node *irn, void *env) {
                req = arch_get_register_req(raenv->aenv, irn, pos);
 
                if (arch_register_req_is(req, should_be_same)) {
-                       ir_node *other = get_irn_n(irn, req->other_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);