Commit 07d8ca2d by Richard Stallman

(record_reg_class): For matching operands...

(record_reg_class): For matching operands, handle
case where the earlier one is not a pseudo like the case
where the later one is not a pseudo.

From-SVN: r2067
parent 21d12b80
...@@ -939,7 +939,24 @@ record_reg_classes (n_alts, n_ops, ops, modes, constraints, insn) ...@@ -939,7 +939,24 @@ record_reg_classes (n_alts, n_ops, ops, modes, constraints, insn)
else else
alt_cost += copy_cost (op, mode, classes[j], 1); alt_cost += copy_cost (op, mode, classes[j], 1);
} }
else if (GET_CODE (ops[j]) != REG
|| REGNO (ops[j]) < FIRST_PSEUDO_REGISTER)
{
/* This op is a pseudo but the one it matches is not. */
/* If we can't put the other operand into a register, this
alternative can't be used. */
if (classes[j] == NO_REGS)
alt_fail = 1;
/* Otherwise, add to the cost of this alternative the cost
to copy the other operand to the register used for this
operand. */
else
alt_cost += copy_cost (ops[j], mode, classes[j], 1);
}
else else
{ {
/* The costs of this operand are the same as that of the /* The costs of this operand are the same as that of the
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment