+2004-01-26 Michael Hayes <m.hayes@elec.canterbury.ac.nz>
+
+ * config/c4x/c4x.c (c4x_check_legit_addr): Rename to
+ c4x_legitimate_address_p. Fix post_modify check.
+ * config/c4x/c4x-protos.h (c4x_check_legit_addr): Adjust.
+ * config/c4x/c4x.h (c4x_check_legit_addr): Adjust.
+
2004-01-25 Kazu Hirata <kazu@cs.umass.edu>
* config/pa/pa-protos.h: Remove the prototype for
(PROMOTE_PROTOTYPES): Remove.
2004-01-26 Michael Hayes <m.hayes@elec.canterbury.ac.nz>
-
+
* config/c4x/c4x.h (LEGITIMIZE_RELOAD_ADDRESS): Handle symref.
2003-04-25 Chris Demetriou <cgd@broadcom.com>
#ifdef RTX_CODE
extern struct rtx_def *c4x_gen_compare_reg (enum rtx_code, rtx, rtx);
-extern int c4x_check_legit_addr (enum machine_mode, rtx, int);
+extern int c4x_legitimate_address_p (enum machine_mode, rtx, int);
extern int c4x_hard_regno_mode_ok (unsigned int, enum machine_mode);
int
-c4x_check_legit_addr (enum machine_mode mode, rtx addr, int strict)
+c4x_legitimate_address_p (enum machine_mode mode, rtx addr, int strict)
{
rtx base = NULL_RTX; /* Base register (AR0-AR7). */
rtx indx = NULL_RTX; /* Index register (IR0,IR1). */
|| (GET_CODE (op1) != PLUS && GET_CODE (op1) != MINUS))
return 0;
base = XEXP (op1, 0);
- if (base != op0)
+ if (! REG_P (base))
+ return 0;
+ if (REGNO (base) != REGNO (op0))
return 0;
if (REG_P (XEXP (op1, 1)))
indx = XEXP (op1, 1);
#define GO_IF_LEGITIMATE_ADDRESS(MODE, X, ADDR) \
{ \
- if (c4x_check_legit_addr (MODE, X, 0)) \
+ if (c4x_legitimate_address_p (MODE, X, 0)) \
goto ADDR; \
}
#define GO_IF_LEGITIMATE_ADDRESS(MODE, X, ADDR) \
{ \
- if (c4x_check_legit_addr (MODE, X, 1)) \
+ if (c4x_legitimate_address_p (MODE, X, 1)) \
goto ADDR; \
}