beinsn: Remove attribute irn from struct be_operand_t.
authorChristoph Mallon <christoph.mallon@gmx.de>
Sun, 25 Nov 2012 14:13:20 +0000 (15:13 +0100)
committerChristoph Mallon <christoph.mallon@gmx.de>
Sun, 25 Nov 2012 14:13:20 +0000 (15:13 +0100)
It is always the same as the irn of the corresponding insn.

ir/be/bechordal.c
ir/be/beinsn.c
ir/be/beinsn_t.h

index 831a427..54e59b1 100644 (file)
@@ -78,7 +78,7 @@ static void pair_up_operands(be_chordal_env_t const *const env, be_insn_t *const
                be_operand_t *const out_op          = &insn->ops[j];
                for (int i = insn->use_start; i < insn->n_ops; ++i) {
                        be_operand_t *const op = &insn->ops[i];
-                       if (op->partner || be_values_interfere(lv, op->irn, op->carrier))
+                       if (op->partner || be_values_interfere(lv, insn->irn, op->carrier))
                                continue;
 
                        bitset_copy(bs, op->regs);
index 4a52deb..78a9b6b 100644 (file)
@@ -62,7 +62,6 @@ be_insn_t *be_scan_insn(be_chordal_env_t const *const env, ir_node *const irn)
                                /* found a def: create a new operand */
                                o.req             = arch_get_irn_register_req(p);
                                o.carrier         = p;
-                               o.irn             = irn;
                                o.partner         = NULL;
                                obstack_grow(obst, &o, sizeof(o));
                                insn->n_ops++;
@@ -73,7 +72,6 @@ be_insn_t *be_scan_insn(be_chordal_env_t const *const env, ir_node *const irn)
                /* only one def, create one operand */
                o.req     = arch_get_irn_register_req(irn);
                o.carrier = irn;
-               o.irn     = irn;
                o.partner = NULL;
                obstack_grow(obst, &o, sizeof(o));
                insn->n_ops++;
@@ -90,7 +88,6 @@ be_insn_t *be_scan_insn(be_chordal_env_t const *const env, ir_node *const irn)
                        /* found a register use, create an operand */
                        o.req     = arch_get_irn_register_req_in(irn, i);
                        o.carrier = op;
-                       o.irn     = irn;
                        o.partner = NULL;
                        obstack_grow(obst, &o, sizeof(o));
                        insn->n_ops++;
index 43525ae..fec66ba 100644 (file)
@@ -36,7 +36,6 @@ typedef struct be_operand_t  be_operand_t;
 typedef struct be_insn_t     be_insn_t;
 
 struct be_operand_t {
-       ir_node *irn;                   /**< Firm node of the insn this operand belongs to */
        ir_node *carrier;               /**< node representing the operand value (Proj or the node itself for defs, the used value for uses) */
        be_operand_t *partner;          /**< used in bechordal later... (TODO what does it do?) */
        const bitset_t *regs;           /**< admissible register bitset */