summaryrefslogtreecommitdiff
path: root/gcc/config/h8300
diff options
context:
space:
mode:
authorlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>1999-09-07 05:49:18 +0000
committerlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>1999-09-07 05:49:18 +0000
commit7014838cdd847f5d22f8b4bff0285ad622b707b5 (patch)
treef1a67b6ea75a7f0da3f06e0a1c60b213f4403168 /gcc/config/h8300
parent713829e97b2cabe9369424002f6efb23a7c86aba (diff)
downloadgcc-7014838cdd847f5d22f8b4bff0285ad622b707b5.tar.gz
Merge in gcc2-ss-010999
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@29150 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/h8300')
-rw-r--r--gcc/config/h8300/h8300.c40
-rw-r--r--gcc/config/h8300/h8300.h23
2 files changed, 33 insertions, 30 deletions
diff --git a/gcc/config/h8300/h8300.c b/gcc/config/h8300/h8300.c
index 4fac366f71d..aa58157284c 100644
--- a/gcc/config/h8300/h8300.c
+++ b/gcc/config/h8300/h8300.c
@@ -22,7 +22,7 @@ the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#include "config.h"
-#include <stdio.h>
+#include "system.h"
#include "rtl.h"
#include "tree.h"
#include "regs.h"
@@ -41,7 +41,6 @@ Boston, MA 02111-1307, USA. */
/* Forward declarations. */
void print_operand_address ();
-char *index ();
static int h8300_interrupt_function_p PROTO ((tree));
static int h8300_monitor_function_p PROTO ((tree));
@@ -954,16 +953,16 @@ function_arg (cum, mode, type, named)
switch (cum->nbytes / UNITS_PER_WORD)
{
case 0:
- result = gen_rtx (REG, mode, 0);
+ result = gen_rtx_REG (mode, 0);
break;
case 1:
- result = gen_rtx (REG, mode, 1);
+ result = gen_rtx_REG (mode, 1);
break;
case 2:
- result = gen_rtx (REG, mode, 2);
+ result = gen_rtx_REG (mode, 2);
break;
case 3:
- result = gen_rtx (REG, mode, 3);
+ result = gen_rtx_REG (mode, 3);
break;
default:
result = 0;
@@ -1858,12 +1857,14 @@ expand_a_shift (mode, code, operands)
/* need a loop to get all the bits we want - we generate the
code at emit time, but need to allocate a scratch reg now */
- emit_insn (gen_rtx
- (PARALLEL, VOIDmode,
+ emit_insn (gen_rtx_PARALLEL
+ (VOIDmode,
gen_rtvec (2,
- gen_rtx (SET, VOIDmode, operands[0],
- gen_rtx (code, mode, operands[0], operands[2])),
- gen_rtx (CLOBBER, VOIDmode, gen_rtx (SCRATCH, QImode, 0)))));
+ gen_rtx_SET (VOIDmode, operands[0],
+ gen_rtx (code, mode, operands[0],
+ operands[2])),
+ gen_rtx_CLOBBER (VOIDmode,
+ gen_rtx_SCRATCH (QImode)))));
return 1;
}
@@ -2791,9 +2792,9 @@ fix_bit_operand (operands, what, type)
/* Ok to have a memory dest. */
if (GET_CODE (operands[0]) == MEM && !EXTRA_CONSTRAINT (operands[0], 'U'))
{
- rtx mem;
- mem = gen_rtx (MEM, GET_MODE (operands[0]),
- copy_to_mode_reg (Pmode, XEXP (operands[0], 0)));
+ rtx mem = gen_rtx_MEM (GET_MODE (operands[0]),
+ copy_to_mode_reg (Pmode,
+ XEXP (operands[0], 0)));
RTX_UNCHANGING_P (mem) = RTX_UNCHANGING_P (operands[0]);
MEM_COPY_ATTRIBUTES (mem, operands[0]);
operands[0] = mem;
@@ -2801,9 +2802,9 @@ fix_bit_operand (operands, what, type)
if (GET_CODE (operands[1]) == MEM && !EXTRA_CONSTRAINT (operands[1], 'U'))
{
- rtx mem;
- mem = gen_rtx (MEM, GET_MODE (operands[1]),
- copy_to_mode_reg (Pmode, XEXP (operands[1], 0)));
+ rtx mem = gen_rtx_MEM (GET_MODE (operands[1]),
+ copy_to_mode_reg (Pmode,
+ XEXP (operands[1], 0)));
RTX_UNCHANGING_P (mem) = RTX_UNCHANGING_P (operands[1]);
MEM_COPY_ATTRIBUTES (mem, operands[0]);
operands[1] = mem;
@@ -2817,8 +2818,9 @@ fix_bit_operand (operands, what, type)
operands[1] = force_reg (QImode, operands[1]);
{
rtx res = gen_reg_rtx (QImode);
- emit_insn (gen_rtx (SET, VOIDmode, res, gen_rtx (type, QImode, operands[1], operands[2])));
- emit_insn (gen_rtx (SET, VOIDmode, operands[0], res));
+ emit_insn (gen_rtx_SET (VOIDmode, res,
+ gen_rtx (type, QImode, operands[1], operands[2])));
+ emit_insn (gen_rtx_SET (VOIDmode, operands[0], res));
}
return 1;
}
diff --git a/gcc/config/h8300/h8300.h b/gcc/config/h8300/h8300.h
index 4ee440ac58d..9e8b68232f2 100644
--- a/gcc/config/h8300/h8300.h
+++ b/gcc/config/h8300/h8300.h
@@ -526,7 +526,7 @@ enum reg_class {
On the H8 the return value is in R0/R1. */
#define FUNCTION_VALUE(VALTYPE, FUNC) \
- gen_rtx (REG, TYPE_MODE (VALTYPE), 0)
+ gen_rtx_REG (TYPE_MODE (VALTYPE), 0)
/* Define how to find the value returned by a library function
assuming the value has mode MODE. */
@@ -534,7 +534,7 @@ enum reg_class {
/* On the h8 the return value is in R0/R1 */
#define LIBCALL_VALUE(MODE) \
- gen_rtx (REG, MODE, 0)
+ gen_rtx_REG (MODE, 0)
/* 1 if N is a possible register number for a function value.
On the H8, R0 is the only register thus used. */
@@ -713,10 +713,11 @@ struct rtx_def *function_arg();
#define INITIALIZE_TRAMPOLINE(TRAMP, FNADDR, CXT) \
{ \
enum machine_mode mode = TARGET_H8300H || TARGET_H8300S? SImode : HImode; \
- emit_move_insn (gen_rtx (MEM, mode, plus_constant ((TRAMP), 2)), CXT); \
- emit_move_insn (gen_rtx (MEM, mode, plus_constant ((TRAMP), 6)), FNADDR); \
- if (TARGET_H8300H || TARGET_H8300S) \
- emit_move_insn (gen_rtx (MEM, QImode, plus_constant ((TRAMP), 6)), GEN_INT (0x5A)); \
+ emit_move_insn (gen_rtx_MEM (mode, plus_constant ((TRAMP), 2)), CXT); \
+ emit_move_insn (gen_rtx_MEM (mode, plus_constant ((TRAMP), 6)), FNADDR); \
+ if (TARGET_H8300H || TARGET_H8300S) \
+ emit_move_insn (gen_rtx_MEM (QImode, plus_constant ((TRAMP), 6)), \
+ GEN_INT (0x5A)); \
}
/* Addressing modes, and classification of registers for them. */
@@ -1387,15 +1388,15 @@ extern int handle_pragma ();
#define INIT_TARGET_OPTABS \
do { \
smul_optab->handlers[(int) HImode].libfunc \
- = gen_rtx (SYMBOL_REF, Pmode, MULHI3_LIBCALL); \
+ = gen_rtx_SYMBOL_REF (Pmode, MULHI3_LIBCALL); \
sdiv_optab->handlers[(int) HImode].libfunc \
- = gen_rtx (SYMBOL_REF, Pmode, DIVHI3_LIBCALL); \
+ = gen_rtx_SYMBOL_REF (Pmode, DIVHI3_LIBCALL); \
udiv_optab->handlers[(int) HImode].libfunc \
- = gen_rtx (SYMBOL_REF, Pmode, UDIVHI3_LIBCALL); \
+ = gen_rtx_SYMBOL_REF (Pmode, UDIVHI3_LIBCALL); \
smod_optab->handlers[(int) HImode].libfunc \
- = gen_rtx (SYMBOL_REF, Pmode, MODHI3_LIBCALL); \
+ = gen_rtx_SYMBOL_REF (Pmode, MODHI3_LIBCALL); \
umod_optab->handlers[(int) HImode].libfunc \
- = gen_rtx (SYMBOL_REF, Pmode, UMODHI3_LIBCALL); \
+ = gen_rtx_SYMBOL_REF (Pmode, UMODHI3_LIBCALL); \
} while (0)
#define MOVE_RATIO 3