summaryrefslogtreecommitdiff
path: root/gcc/config/rx/rx.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/config/rx/rx.h')
-rw-r--r--gcc/config/rx/rx.h25
1 files changed, 18 insertions, 7 deletions
diff --git a/gcc/config/rx/rx.h b/gcc/config/rx/rx.h
index afaa07b0bc5..b3a12690b08 100644
--- a/gcc/config/rx/rx.h
+++ b/gcc/config/rx/rx.h
@@ -207,7 +207,7 @@ enum reg_class
#define BASE_REG_CLASS GR_REGS
#define INDEX_REG_CLASS GR_REGS
-#define FIRST_PSEUDO_REGISTER 16
+#define FIRST_PSEUDO_REGISTER 17
#define REGNO_REG_CLASS(REGNO) ((REGNO) < FIRST_PSEUDO_REGISTER \
? GR_REGS : NO_REGS)
@@ -219,6 +219,7 @@ enum reg_class
#define STATIC_CHAIN_REGNUM 8
#define TRAMPOLINE_TEMP_REGNUM 9
#define STRUCT_VAL_REGNUM 15
+#define CC_REGNUM 16
/* This is the register which is used to hold the address of the start
of the small data area, if that feature is being used. Note - this
@@ -245,12 +246,12 @@ enum reg_class
#define FIXED_REGISTERS \
{ \
- 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 \
+ 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1 \
}
#define CALL_USED_REGISTERS \
{ \
- 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1 \
+ 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1 \
}
#define CONDITIONAL_REGISTER_USAGE \
@@ -351,7 +352,7 @@ typedef unsigned int CUMULATIVE_ARGS;
#define REGISTER_NAMES \
{ \
"r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", \
- "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15" \
+ "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15", "cc" \
};
#define ADDITIONAL_REGISTER_NAMES \
@@ -609,9 +610,6 @@ typedef unsigned int CUMULATIVE_ARGS;
they contain are always computed between two same-section symbols. */
#define JUMP_TABLES_IN_TEXT_SECTION (flag_pic)
-#define CC_NO_CARRY 0400
-#define NOTICE_UPDATE_CC(EXP, INSN) rx_notice_update_cc (EXP, INSN)
-
extern int rx_float_compare_mode;
/* This is a version of REG_P that also returns TRUE for SUBREGs. */
@@ -646,3 +644,16 @@ extern int rx_float_compare_mode;
/* This macro is used to decide when RX FPU instructions can be used. */
#define ALLOW_RX_FPU_INSNS (TARGET_USE_FPU)
+
+#define BRANCH_COST(SPEED,PREDICT) 1
+#define REGISTER_MOVE_COST(MODE,FROM,TO) 2
+
+#define SELECT_CC_MODE(OP,X,Y) \
+ (GET_MODE_CLASS (GET_MODE (X)) == MODE_FLOAT ? CC_ZSmode : \
+ (GET_CODE (X) == PLUS || GET_CODE (X) == MINUS ? CC_ZSCmode : \
+ (GET_CODE (X) == ABS ? CC_ZSOmode : \
+ (GET_CODE (X) == AND || GET_CODE (X) == NOT || GET_CODE (X) == IOR \
+ || GET_CODE (X) == XOR || GET_CODE (X) == ROTATE \
+ || GET_CODE (X) == ROTATERT || GET_CODE (X) == ASHIFTRT \
+ || GET_CODE (X) == LSHIFTRT || GET_CODE (X) == ASHIFT ? CC_ZSmode : \
+ CCmode))))