Use only the real temp for daglabels.

This fixes the bogus temps for "*to = *from++;", but qfcc ices due to the
operand types being lost. It seems alias operands need to be resurrected,
if only for code output by dags.
This commit is contained in:
Bill Currie 2012-12-11 15:20:52 +09:00
parent 50b0bd0b95
commit 8452f69a21
1 changed files with 4 additions and 0 deletions

View File

@ -153,6 +153,8 @@ operand_label (dag_t *dag, operand_t *op)
return 0;
if (op->op_type == op_temp) {
while (op->o.tempop.alias)
op = op->o.tempop.alias;
if (op->o.tempop.daglabel)
return op->o.tempop.daglabel;
label = new_label (dag);
@ -214,6 +216,8 @@ dag_node (operand_t *op)
if (def->daglabel)
node = def->daglabel->dagnode;
} else if (op->op_type == op_temp) {
while (op->o.tempop.alias)
op = op->o.tempop.alias;
if (op->o.tempop.daglabel)
node = op->o.tempop.daglabel->dagnode;
} else if (op->op_type == op_value) {