home *** CD-ROM | disk | FTP | other *** search
- *** gcc/config/mips.md.orig Thu Sep 21 11:06:18 1989
- --- gcc/config/mips.md Wed Dec 20 14:38:31 1989
- ***************
- *** 528,534 ****
- (define_insn "andsi3"
- [(set (match_operand:SI 0 "general_operand" "=r,&r")
- (and:SI (match_operand:SI 1 "general_operand" "%r,r")
- ! (match_operand:SI 2 "general_operand" "rJ,I")))]
- ""
- "*
- {
- --- 528,534 ----
- (define_insn "andsi3"
- [(set (match_operand:SI 0 "general_operand" "=r,&r")
- (and:SI (match_operand:SI 1 "general_operand" "%r,r")
- ! (match_operand:SI 2 "general_operand" "rJ,K")))]
- ""
- "*
- {
- ***************
- *** 535,541 ****
- rtx xops[3];
- if (GET_CODE (operands[2]) == CONST_INT)
- {
- ! if (CONST_OK_FOR_LETTER_P (INTVAL (operands[2]), 'I'))
- if (INTVAL (operands[2]) >= 0)
- {
- return \"andi\\t%0,%1,%x2\\t#andsi3\\t%1,%d2 -> %0\";
- --- 535,541 ----
- rtx xops[3];
- if (GET_CODE (operands[2]) == CONST_INT)
- {
- ! if (CONST_OK_FOR_LETTER_P (INTVAL (operands[2]), 'K'))
- if (INTVAL (operands[2]) >= 0)
- {
- return \"andi\\t%0,%1,%x2\\t#andsi3\\t%1,%d2 -> %0\";
- ***************
- *** 607,619 ****
- (define_insn "iorsi3"
- [(set (match_operand:SI 0 "general_operand" "=r")
- (ior:SI (match_operand:SI 1 "general_operand" "%r")
- ! (match_operand:SI 2 "general_operand" "rIJ")))]
- ""
- "*
- {
- if (GET_CODE (operands[2]) == CONST_INT)
- {
- ! if (CONST_OK_FOR_LETTER_P (INTVAL (operands[2]), 'I'))
- {
- return \"ori\\t%0,%1,%x2\\t#iorsi3\\t%1,%d2 -> %0\";
- }
- --- 607,619 ----
- (define_insn "iorsi3"
- [(set (match_operand:SI 0 "general_operand" "=r")
- (ior:SI (match_operand:SI 1 "general_operand" "%r")
- ! (match_operand:SI 2 "general_operand" "rKJ")))]
- ""
- "*
- {
- if (GET_CODE (operands[2]) == CONST_INT)
- {
- ! if (CONST_OK_FOR_LETTER_P (INTVAL (operands[2]), 'K'))
- {
- return \"ori\\t%0,%1,%x2\\t#iorsi3\\t%1,%d2 -> %0\";
- }
- ***************
- *** 669,681 ****
- (define_insn "xorsi3"
- [(set (match_operand:SI 0 "general_operand" "=r")
- (xor:SI (match_operand:SI 1 "general_operand" "%r")
- ! (match_operand:SI 2 "general_operand" "rIJ")))]
- ""
- "*
- {
- if (GET_CODE (operands[2]) == CONST_INT)
- {
- ! if (CONST_OK_FOR_LETTER_P (INTVAL (operands[2]), 'I'))
- {
- return \"xori\\t%0,%1,%x2\\t#xorsi3\\t%1,%d2 -> %0\";
- }
- --- 669,681 ----
- (define_insn "xorsi3"
- [(set (match_operand:SI 0 "general_operand" "=r")
- (xor:SI (match_operand:SI 1 "general_operand" "%r")
- ! (match_operand:SI 2 "general_operand" "rKJ")))]
- ""
- "*
- {
- if (GET_CODE (operands[2]) == CONST_INT)
- {
- ! if (CONST_OK_FOR_LETTER_P (INTVAL (operands[2]), 'K'))
- {
- return \"xori\\t%0,%1,%x2\\t#xorsi3\\t%1,%d2 -> %0\";
- }
- *** gcc/config/tm-mips.h.orig Sat Sep 23 23:52:22 1989
- --- gcc/config/tm-mips.h Mon Dec 4 14:42:42 1989
- ***************
- *** 546,562 ****
- C is the letter, and VALUE is a constant value.
- Return 1 if VALUE is in the range specified by C. */
-
- ! /* For MIPS, `I' is used for the range of constants an insn
- ! can actually contain (16 bits signed integers).
- `J' is used for the range which is just zero (since that is
- available as $R0).
- */
-
- ! #define SMALL_INT(X) ((unsigned) (INTVAL (X) + 0x10000) < 0x20000)
-
- #define CONST_OK_FOR_LETTER_P(VALUE, C) \
- ! ((C) == 'I' ? (unsigned) ((VALUE) + 0x10000) < 0x20000 \
- : (C) == 'J' ? (VALUE) == 0 \
- : 0)
-
- /* Similar, but for floating constants, and defining letters G and H.
- --- 546,566 ----
- C is the letter, and VALUE is a constant value.
- Return 1 if VALUE is in the range specified by C. */
-
- ! /* For MIPS, `I' is used for the range of constants an arithmetic insn
- ! can actually contain (16 bits sign-extended integers).
- `J' is used for the range which is just zero (since that is
- available as $R0).
- + `K' is used for the range of constants a logical insn
- + can actually contain (16 bit zero-extended integers).
- */
-
- ! #define SMALL_INT_SX(X) ((-32768 <= (X)) && ((X) <= 32767))
- ! #define SMALL_INT_ZX(X) ((0 <= (X)) && ((X) <= 65535))
-
- #define CONST_OK_FOR_LETTER_P(VALUE, C) \
- ! ((C) == 'I' ? SMALL_INT_SX (VALUE) \
- : (C) == 'J' ? (VALUE) == 0 \
- + : (C) == 'K' ? SMALL_INT_ZX (VALUE) \
- : 0)
-
- /* Similar, but for floating constants, and defining letters G and H.
- ***************
- *** 867,873 ****
- #define FUNCTION_PROLOGUE(FILE, SIZE) \
- { register int regno; \
- register int mask = 0, fmask=0; \
- ! static char dont_save_regs[] = CALL_USED_REGISTERS; \
- register int push_loc = 0,tsize = SIZE+8; \
- char *fp_str; \
- extern char *reg_numchar[]; \
- --- 871,877 ----
- #define FUNCTION_PROLOGUE(FILE, SIZE) \
- { register int regno; \
- register int mask = 0, fmask=0; \
- ! extern char call_used_regs []; \
- register int push_loc = 0,tsize = SIZE+8; \
- char *fp_str; \
- extern char *reg_numchar[]; \
- ***************
- *** 877,886 ****
- : reg_numchar[STACK_POINTER_REGNUM]; \
- for (regno = 0; regno < 32; regno++) \
- if ( MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !dont_save_regs[regno])) \
- {tsize += 4; mask |= 1 << regno;} \
- for (regno = 32; regno < FIRST_PSEUDO_REGISTER; regno += 2) \
- ! if (regs_ever_live[regno] && !dont_save_regs[regno]) \
- {tsize += 8; fmask |= 1 << (regno-32);} \
- if (THIS_VARARGS_SUSPECTED) tsize += 16; \
- fprintf (FILE," #PROLOGUE\n"); \
- --- 881,890 ----
- : reg_numchar[STACK_POINTER_REGNUM]; \
- for (regno = 0; regno < 32; regno++) \
- if ( MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !call_used_regs[regno])) \
- {tsize += 4; mask |= 1 << regno;} \
- for (regno = 32; regno < FIRST_PSEUDO_REGISTER; regno += 2) \
- ! if (regs_ever_live[regno] && !call_used_regs[regno]) \
- {tsize += 8; fmask |= 1 << (regno-32);} \
- if (THIS_VARARGS_SUSPECTED) tsize += 16; \
- fprintf (FILE," #PROLOGUE\n"); \
- ***************
- *** 910,916 ****
- for (regno = 31; regno >= 30; regno--) \
- { \
- if (MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !dont_save_regs[regno])) \
- { \
- fprintf (FILE, "\tsw\t%s,%d(%s)\n", \
- TARGET_NAME_REGS ? reg_names[regno] : reg_numchar[regno], \
- --- 914,920 ----
- for (regno = 31; regno >= 30; regno--) \
- { \
- if (MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !call_used_regs[regno])) \
- { \
- fprintf (FILE, "\tsw\t%s,%d(%s)\n", \
- TARGET_NAME_REGS ? reg_names[regno] : reg_numchar[regno], \
- ***************
- *** 939,945 ****
- for (regno = 29; regno >= 0; regno--) \
- { \
- if (MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !dont_save_regs[regno])) \
- { \
- fprintf (FILE, "\tsw\t%s,%d(%s)\n", \
- TARGET_NAME_REGS ? reg_names[regno] : reg_numchar[regno], \
- --- 943,949 ----
- for (regno = 29; regno >= 0; regno--) \
- { \
- if (MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !call_used_regs[regno])) \
- { \
- fprintf (FILE, "\tsw\t%s,%d(%s)\n", \
- TARGET_NAME_REGS ? reg_names[regno] : reg_numchar[regno], \
- ***************
- *** 949,955 ****
- } \
- fprintf (FILE, " #\t.fmask\t0x%x\n", fmask); \
- for (regno = 32; regno < FIRST_PSEUDO_REGISTER; regno += 2) \
- ! if (regs_ever_live[regno] && !dont_save_regs[regno]) \
- { \
- fprintf (FILE, "\ts.d\t%s,%d(%s)\n", \
- (TARGET_NAME_REGS) ? reg_names[regno] : reg_numchar[regno], \
- --- 953,959 ----
- } \
- fprintf (FILE, " #\t.fmask\t0x%x\n", fmask); \
- for (regno = 32; regno < FIRST_PSEUDO_REGISTER; regno += 2) \
- ! if (regs_ever_live[regno] && !call_used_regs[regno]) \
- { \
- fprintf (FILE, "\ts.d\t%s,%d(%s)\n", \
- (TARGET_NAME_REGS) ? reg_names[regno] : reg_numchar[regno], \
- ***************
- *** 1011,1017 ****
- register int fmask = 0; \
- char *fp_str; \
- char *sp_str; \
- ! static char dont_save_regs[] = CALL_USED_REGISTERS; \
- register int push_loc ; \
- extern char *reg_numchar[]; \
- extern char *current_function_name; \
- --- 1015,1021 ----
- register int fmask = 0; \
- char *fp_str; \
- char *sp_str; \
- ! extern char call_used_regs []; \
- register int push_loc ; \
- extern char *reg_numchar[]; \
- extern char *current_function_name; \
- ***************
- *** 1033,1044 ****
- ); \
- for (regno = 0; regno < 32; regno++) \
- if ( MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !dont_save_regs[regno])) \
- mask |= 1 << regno; \
- fprintf (FILE, " #\t.mask\t0x%x\n", mask); \
- for (regno = 31; regno >= 0; regno--) \
- { if ( MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !dont_save_regs[regno])) \
- { \
- fprintf (FILE,"\tlw\t%s,%d(%s)\n", \
- TARGET_NAME_REGS ? reg_names[regno] \
- --- 1037,1048 ----
- ); \
- for (regno = 0; regno < 32; regno++) \
- if ( MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !call_used_regs[regno])) \
- mask |= 1 << regno; \
- fprintf (FILE, " #\t.mask\t0x%x\n", mask); \
- for (regno = 31; regno >= 0; regno--) \
- { if ( MUST_SAVE_REG_LOGUES \
- ! || (regs_ever_live[regno] && !call_used_regs[regno])) \
- { \
- fprintf (FILE,"\tlw\t%s,%d(%s)\n", \
- TARGET_NAME_REGS ? reg_names[regno] \
- ***************
- *** 1052,1063 ****
- if ( THIS_VARARGS_SUSPECTED && (regno == 30)) push_loc += 16; \
- } \
- for (regno = 32; regno < FIRST_PSEUDO_REGISTER; regno += 2) \
- ! if (regs_ever_live[regno] && !dont_save_regs[regno]) \
- fmask |= 1 << (regno-32); \
- fprintf (FILE, " #\t.fmask\t0x%x\n", fmask); \
- for (regno = 32; regno < FIRST_PSEUDO_REGISTER; regno += 2) \
- { \
- ! if (regs_ever_live[regno] && !dont_save_regs[regno]) \
- { \
- fprintf (FILE,"\tl.d\t%s,%d(%s)\n", \
- ( ( TARGET_NAME_REGS) ? reg_names[regno] \
- --- 1056,1067 ----
- if ( THIS_VARARGS_SUSPECTED && (regno == 30)) push_loc += 16; \
- } \
- for (regno = 32; regno < FIRST_PSEUDO_REGISTER; regno += 2) \
- ! if (regs_ever_live[regno] && !call_used_regs[regno]) \
- fmask |= 1 << (regno-32); \
- fprintf (FILE, " #\t.fmask\t0x%x\n", fmask); \
- for (regno = 32; regno < FIRST_PSEUDO_REGISTER; regno += 2) \
- { \
- ! if (regs_ever_live[regno] && !call_used_regs[regno]) \
- { \
- fprintf (FILE,"\tl.d\t%s,%d(%s)\n", \
- ( ( TARGET_NAME_REGS) ? reg_names[regno] \
- *** gcc/config/xm-mips.h.orig Wed Apr 5 16:25:08 1989
- --- gcc/config/xm-mips.h Mon Dec 4 14:43:27 1989
- ***************
- *** 35,37 ****
- --- 35,46 ----
- /* Arguments to use with `exit'. */
- #define SUCCESS_EXIT_CODE 0
- #define FATAL_EXIT_CODE 33
- +
- + /* If compiled with GNU C, use the built-in alloca. If not, we're
- + using the native (Gwyn/Stallman PD) version. */
- + #ifdef __GNUC__
- + #define alloca __builtin_alloca
- + #else
- + #define USE_C_ALLOCA
- + #endif
- +
- *** gcc/config/out-mips.c.orig Mon Feb 12 08:55:48 1990
- --- gcc/config/out-mips.c Tue Dec 5 08:46:57 1989
- ***************
- *** 38,44 ****
- enum machine_mode mode;
- {
- return (register_operand (op, mode)
- ! || (GET_CODE (op) == CONST_INT && SMALL_INT (op)));
- }
-
- /* Return truth value of whether OP can be used as an operand in a two
- --- 38,44 ----
- enum machine_mode mode;
- {
- return (register_operand (op, mode)
- ! || (GET_CODE (op) == CONST_INT && SMALL_INT_SX (INTVAL (op))));
- }
-
- /* Return truth value of whether OP can be used as an operand in a two
- ***************
- *** 59,65 ****
- rtx op;
- enum machine_mode mode;
- {
- ! return (GET_CODE (op) == CONST_INT && SMALL_INT (op));
- }
-
-
- --- 59,65 ----
- rtx op;
- enum machine_mode mode;
- {
- ! return (GET_CODE (op) == CONST_INT && SMALL_INT_ZX (INTVAL (op)));
- }
-
-
-