case 'X':
result = 1;
+ break;
case 'g':
if (general_operand (op, VOIDmode))
result = 1;
}
#ifdef EXTRA_CONSTRAINT_STR
- if (EXTRA_CONSTRAINT_STR (op, c, constraint))
+ else if (EXTRA_CONSTRAINT_STR (op, c, constraint))
+ result = 1;
+ else if (EXTRA_MEMORY_CONSTRAINT (c, constraint)
+ /* Every memory operand can be reloaded to fit. */
+ && memory_operand (op, VOIDmode))
+ result = 1;
+ else if (EXTRA_ADDRESS_CONSTRAINT (c, constraint)
+ /* Every address operand can be reloaded to fit. */
+ && address_operand (op, VOIDmode))
result = 1;
- if (EXTRA_MEMORY_CONSTRAINT (c, constraint))
- {
- /* Every memory operand can be reloaded to fit. */
- if (memory_operand (op, VOIDmode))
- result = 1;
- }
- if (EXTRA_ADDRESS_CONSTRAINT (c, constraint))
- {
- /* Every address operand can be reloaded to fit. */
- if (address_operand (op, VOIDmode))
- result = 1;
- }
#endif
break;
}
extract_insn (insn);
recog_data.insn = insn;
}
-/* Do cached extract_insn, constrain_operand and complain about failures.
+/* Do cached extract_insn, constrain_operands and complain about failures.
Used by insn_attrtab. */
void
extract_constrain_insn_cached (rtx insn)
&& !constrain_operands (reload_completed))
fatal_insn_not_found (insn);
}
-/* Do cached constrain_operand and complain about failures. */
+/* Do cached constrain_operands and complain about failures. */
int
constrain_operands_cached (int strict)
{
else if (EXTRA_CONSTRAINT_STR (op, c, p))
win = 1;
- if (EXTRA_MEMORY_CONSTRAINT (c, p))
- {
- /* Every memory operand can be reloaded to fit. */
- if (strict < 0 && GET_CODE (op) == MEM)
- win = 1;
-
- /* Before reload, accept what reload can turn into mem. */
- if (strict < 0 && CONSTANT_P (op))
- win = 1;
-
- /* During reload, accept a pseudo */
- if (reload_in_progress && GET_CODE (op) == REG
- && REGNO (op) >= FIRST_PSEUDO_REGISTER)
- win = 1;
- }
- if (EXTRA_ADDRESS_CONSTRAINT (c, p))
- {
- /* Every address operand can be reloaded to fit. */
- if (strict < 0)
- win = 1;
- }
+ else if (EXTRA_MEMORY_CONSTRAINT (c, p)
+ /* Every memory operand can be reloaded to fit. */
+ && ((strict < 0 && GET_CODE (op) == MEM)
+ /* Before reload, accept what reload can turn
+ into mem. */
+ || (strict < 0 && CONSTANT_P (op))
+ /* During reload, accept a pseudo */
+ || (reload_in_progress && GET_CODE (op) == REG
+ && REGNO (op) >= FIRST_PSEUDO_REGISTER)))
+ win = 1;
+ else if (EXTRA_ADDRESS_CONSTRAINT (c, p)
+ /* Every address operand can be reloaded to fit. */
+ && strict < 0)
+ win = 1;
#endif
break;
}
win = 1;
/* If the address was already reloaded,
we win as well. */
- if (GET_CODE (operand) == MEM && address_reloaded[i])
+ else if (GET_CODE (operand) == MEM
+ && address_reloaded[i])
win = 1;
/* Likewise if the address will be reloaded because
reg_equiv_address is nonzero. For reg_equiv_mem
we have to check. */
- if (GET_CODE (operand) == REG
- && REGNO (operand) >= FIRST_PSEUDO_REGISTER
- && reg_renumber[REGNO (operand)] < 0
- && ((reg_equiv_mem[REGNO (operand)] != 0
- && EXTRA_CONSTRAINT_STR (reg_equiv_mem[REGNO (operand)], c, p))
- || (reg_equiv_address[REGNO (operand)] != 0)))
+ else if (GET_CODE (operand) == REG
+ && REGNO (operand) >= FIRST_PSEUDO_REGISTER
+ && reg_renumber[REGNO (operand)] < 0
+ && ((reg_equiv_mem[REGNO (operand)] != 0
+ && EXTRA_CONSTRAINT_STR (reg_equiv_mem[REGNO (operand)], c, p))
+ || (reg_equiv_address[REGNO (operand)] != 0)))
win = 1;
/* If we didn't already win, we can reload