+2001-02-03 Herman A.J. ten Brugge <Haj.Ten.Brugge@net.HCC.nl>
+
+ * c4x.c (group1_reg_operand, group1_mem_operand, arx_reg_operand,
+ c4x_arn_reg_operand, c4x_arn_mem_operand): Do not check register
+ number before reload.
+ (c4x_adjust_cost): Return zero before reload.
+ * c4x.md (load_immed_address+1, load_immed_address+2): Do not
+ split before reload.
+
2001-02-03 Herman A.J. ten Brugge <Haj.Ten.Brugge@net.HCC.nl>
* c4x.c (c4x_hard_regno_rename_ok): New.
return 0;
if (GET_CODE (op) == SUBREG)
op = SUBREG_REG (op);
- return REG_P (op) && IS_GROUP1_REG (op);
+ return REG_P (op) && (! reload_completed || IS_GROUP1_REG (op));
}
rtx op0 = XEXP (op, 0);
rtx op1 = XEXP (op, 1);
- if (((GET_CODE (op0) == REG) && IS_GROUP1_REG (op0))
- || ((GET_CODE (op1) == REG) && IS_GROUP1_REG (op1)))
+ if ((REG_P (op0) && (! reload_completed || IS_GROUP1_REG (op0)))
+ || (REG_P (op1) && (! reload_completed || IS_GROUP1_REG (op1))))
return 1;
}
- else if ((REG_P (op)) && IS_GROUP1_REG (op))
+ else if ((REG_P (op)) && (! reload_completed || IS_GROUP1_REG (op)))
return 1;
}
return 0;
if (GET_CODE (op) == SUBREG)
op = SUBREG_REG (op);
- return REG_P (op) && IS_ADDR_REG (op);
+ return REG_P (op) && (! reload_completed || IS_ADDR_REG (op));
}
return 0;
if (GET_CODE (op) == SUBREG)
op = SUBREG_REG (op);
- return REG_P (op) && (REGNO (op) == regno);
+ return REG_P (op) && (! reload_completed || (REGNO (op) == regno));
}
op = XEXP (op, 0);
case REG:
- if (REG_P (op) && (REGNO (op) == regno))
- return 1;
- break;
+ return REG_P (op) && (! reload_completed || (REGNO (op) == regno));
case PRE_MODIFY:
case POST_MODIFY:
- if (REG_P (XEXP (op, 0)) && (REGNO (XEXP (op, 0)) == regno))
+ if (REG_P (XEXP (op, 0)) && (! reload_completed
+ || (REGNO (XEXP (op, 0)) == regno)))
return 1;
if (REG_P (XEXP (XEXP (op, 1), 1))
- && (REGNO (XEXP (XEXP (op, 1), 1)) == regno))
+ && (! reload_completed
+ || (REGNO (XEXP (XEXP (op, 1), 1)) == regno)))
return 1;
break;
rtx op0 = XEXP (op, 0);
rtx op1 = XEXP (op, 1);
- if (((GET_CODE (op0) == REG) && (REGNO (op0) == regno))
- || ((GET_CODE (op1) == REG) && (REGNO (op1) == regno)))
+ if ((REG_P (op0) && (! reload_completed
+ || (REGNO (op0) == regno)))
+ || (REG_P (op1) && (! reload_completed
+ || (REGNO (op1) == regno))))
return 1;
}
break;
{
/* Don't worry about this until we know what registers have been
assigned. */
- if (! reload_completed)
+ if (flag_schedule_insns == 0 && ! reload_completed)
return 0;
/* How do we handle dependencies where a read followed by another
(define_split
[(set (match_operand:QI 0 "std_reg_operand" "")
(match_operand:QI 1 "symbolic_address_operand" ""))]
- "! TARGET_C3X && ! TARGET_TI"
+ "reload_completed && ! TARGET_C3X && ! TARGET_TI"
[(set (match_dup 0) (high:QI (match_dup 1)))
(set (match_dup 0) (lo_sum:QI (match_dup 0) (match_dup 1)))]
"")
[(set (match_operand:QI 0 "std_reg_operand" "")
(match_operand:QI 1 "symbolic_address_operand" ""))
(clobber (reg:QI 16))]
- "! TARGET_C3X && ! TARGET_TI"
+ "reload_completed && ! TARGET_C3X && ! TARGET_TI"
[(set (match_dup 0) (high:QI (match_dup 1)))
(set (match_dup 0) (lo_sum:QI (match_dup 0) (match_dup 1)))]
"")
[(set (match_operand:QI 0 "reg_operand" "")
(match_operand:QI 1 "symbolic_address_operand" ""))
(clobber (reg:QI 16))]
- "! TARGET_SMALL
- && (TARGET_C3X || TARGET_TI
- || (reload_completed
- && ! std_reg_operand (operands[0], QImode)))"
+ "reload_completed
+ && ! TARGET_SMALL
+ && (TARGET_C3X || TARGET_TI || ! std_reg_operand (operands[0], QImode))"
[(set (match_dup 2) (high:QI (match_dup 3)))
(set (match_dup 0) (match_dup 4))
(use (match_dup 1))]
[(set (match_operand:QI 0 "reg_operand" "")
(match_operand:QI 1 "symbolic_address_operand" ""))
(clobber (reg:QI 16))]
- "TARGET_SMALL
- && (TARGET_C3X || TARGET_TI
- || (reload_completed
- && ! std_reg_operand (operands[0], QImode)))"
+ "reload_completed
+ && TARGET_SMALL
+ && (TARGET_C3X || TARGET_TI || ! std_reg_operand (operands[0], QImode))"
[(set (match_dup 0) (match_dup 2))
(use (match_dup 1))]
"