Commit f1777882 by Kazu Hirata Committed by Kazu Hirata

arm.c: Convert to ISO-C.

	* config/arm/arm.c: Convert to ISO-C.
	* config/avr/avr.h: Likewise.
	* config/fr30/fr30.c: Likewise.
	* config/ip2k/ip2k.c: Likewise.
	* config/mn10300/mn10300.c: Likewise.

From-SVN: r74901
parent 5785c0ed
2003-12-21 Kazu Hirata <kazu@cs.umass.edu>
* config/arm/arm.c: Convert to ISO-C.
* config/avr/avr.h: Likewise.
* config/fr30/fr30.c: Likewise.
* config/ip2k/ip2k.c: Likewise.
* config/mn10300/mn10300.c: Likewise.
2003-12-20 Andrew Pinski <pinskia@gcc.gnu.org> 2003-12-20 Andrew Pinski <pinskia@gcc.gnu.org>
Matt Thomas <matt@3am-software.com> Matt Thomas <matt@3am-software.com>
......
...@@ -13008,7 +13008,7 @@ aof_globalize_label (FILE *stream, const char *name) ...@@ -13008,7 +13008,7 @@ aof_globalize_label (FILE *stream, const char *name)
} }
static void static void
aof_file_start () aof_file_start (void)
{ {
fputs ("__r0\tRN\t0\n", asm_out_file); fputs ("__r0\tRN\t0\n", asm_out_file);
fputs ("__a1\tRN\t0\n", asm_out_file); fputs ("__a1\tRN\t0\n", asm_out_file);
......
...@@ -1644,7 +1644,7 @@ do { \ ...@@ -1644,7 +1644,7 @@ do { \
#define EXTRA_SECTION_FUNCTIONS \ #define EXTRA_SECTION_FUNCTIONS \
\ \
void \ void \
progmem_section () \ progmem_section (void) \
{ \ { \
if (in_section != in_progmem) \ if (in_section != in_progmem) \
{ \ { \
......
...@@ -154,9 +154,7 @@ struct gcc_target targetm = TARGET_INITIALIZER; ...@@ -154,9 +154,7 @@ struct gcc_target targetm = TARGET_INITIALIZER;
for the current function. As a side effect it fills in the for the current function. As a side effect it fills in the
current_frame_info structure, if the data is available. */ current_frame_info structure, if the data is available. */
unsigned int unsigned int
fr30_compute_frame_size (from_reg, to_reg) fr30_compute_frame_size (int from_reg, int to_reg)
int from_reg;
int to_reg;
{ {
int regno; int regno;
unsigned int return_value; unsigned int return_value;
...@@ -219,7 +217,7 @@ fr30_compute_frame_size (from_reg, to_reg) ...@@ -219,7 +217,7 @@ fr30_compute_frame_size (from_reg, to_reg)
insn to prevent such scheduling. */ insn to prevent such scheduling. */
void void
fr30_expand_prologue () fr30_expand_prologue (void)
{ {
int regno; int regno;
rtx insn; rtx insn;
...@@ -347,7 +345,7 @@ fr30_expand_prologue () ...@@ -347,7 +345,7 @@ fr30_expand_prologue ()
In some cases, it might be necessary to emit a barrier instruction as the In some cases, it might be necessary to emit a barrier instruction as the
first insn to prevent such scheduling. */ first insn to prevent such scheduling. */
void void
fr30_expand_epilogue () fr30_expand_epilogue (void)
{ {
int regno; int regno;
...@@ -406,11 +404,10 @@ fr30_expand_epilogue () ...@@ -406,11 +404,10 @@ fr30_expand_epilogue ()
ARG_REGS_USED_SO_FAR has *not* been updated for the last named argument ARG_REGS_USED_SO_FAR has *not* been updated for the last named argument
which has type TYPE and mode MODE, and we rely on this fact. */ which has type TYPE and mode MODE, and we rely on this fact. */
void void
fr30_setup_incoming_varargs (arg_regs_used_so_far, int_mode, type, pretend_size) fr30_setup_incoming_varargs (CUMULATIVE_ARGS arg_regs_used_so_far,
CUMULATIVE_ARGS arg_regs_used_so_far; int int_mode,
int int_mode; tree type ATTRIBUTE_UNUSED,
tree type ATTRIBUTE_UNUSED; int *pretend_size)
int * pretend_size;
{ {
enum machine_mode mode = (enum machine_mode)int_mode; enum machine_mode mode = (enum machine_mode)int_mode;
int size; int size;
...@@ -440,9 +437,7 @@ fr30_setup_incoming_varargs (arg_regs_used_so_far, int_mode, type, pretend_size) ...@@ -440,9 +437,7 @@ fr30_setup_incoming_varargs (arg_regs_used_so_far, int_mode, type, pretend_size)
/* Print a memory address as an operand to reference that memory location. */ /* Print a memory address as an operand to reference that memory location. */
void void
fr30_print_operand_address (stream, address) fr30_print_operand_address (FILE *stream, rtx address)
FILE * stream;
rtx address;
{ {
switch (GET_CODE (address)) switch (GET_CODE (address))
{ {
...@@ -461,10 +456,7 @@ fr30_print_operand_address (stream, address) ...@@ -461,10 +456,7 @@ fr30_print_operand_address (stream, address)
/* Print an operand. */ /* Print an operand. */
void void
fr30_print_operand (file, x, code) fr30_print_operand (FILE *file, rtx x, int code)
FILE * file;
rtx x;
int code;
{ {
rtx x0; rtx x0;
...@@ -665,9 +657,7 @@ fr30_print_operand (file, x, code) ...@@ -665,9 +657,7 @@ fr30_print_operand (file, x, code)
/* Compute the number of word sized registers needed to hold a /* Compute the number of word sized registers needed to hold a
function argument of mode INT_MODE and tree type TYPE. */ function argument of mode INT_MODE and tree type TYPE. */
int int
fr30_num_arg_regs (int_mode, type) fr30_num_arg_regs (int int_mode, tree type)
int int_mode;
tree type;
{ {
enum machine_mode mode = (enum machine_mode) int_mode; enum machine_mode mode = (enum machine_mode) int_mode;
int size; int size;
...@@ -692,11 +682,8 @@ fr30_num_arg_regs (int_mode, type) ...@@ -692,11 +682,8 @@ fr30_num_arg_regs (int_mode, type)
parameters to the function. */ parameters to the function. */
int int
fr30_function_arg_partial_nregs (cum, int_mode, type, named) fr30_function_arg_partial_nregs (CUMULATIVE_ARGS cum, int int_mode,
CUMULATIVE_ARGS cum; tree type, int named)
int int_mode;
tree type;
int named;
{ {
/* Unnamed arguments, ie those that are prototyped as ... /* Unnamed arguments, ie those that are prototyped as ...
are always passed on the stack. are always passed on the stack.
...@@ -718,9 +705,7 @@ fr30_function_arg_partial_nregs (cum, int_mode, type, named) ...@@ -718,9 +705,7 @@ fr30_function_arg_partial_nregs (cum, int_mode, type, named)
} }
static rtx static rtx
fr30_pass_by_reference (valist, type) fr30_pass_by_reference (tree valist, tree type)
tree valist;
tree type;
{ {
tree type_ptr; tree type_ptr;
tree type_ptr_ptr; tree type_ptr_ptr;
...@@ -739,9 +724,7 @@ fr30_pass_by_reference (valist, type) ...@@ -739,9 +724,7 @@ fr30_pass_by_reference (valist, type)
} }
static rtx static rtx
fr30_pass_by_value (valist, type) fr30_pass_by_value (tree valist, tree type)
tree valist;
tree type;
{ {
HOST_WIDE_INT size = int_size_in_bytes (type); HOST_WIDE_INT size = int_size_in_bytes (type);
HOST_WIDE_INT rsize; HOST_WIDE_INT rsize;
...@@ -775,9 +758,7 @@ fr30_pass_by_value (valist, type) ...@@ -775,9 +758,7 @@ fr30_pass_by_value (valist, type)
/* Implement `va_arg'. */ /* Implement `va_arg'. */
rtx rtx
fr30_va_arg (valist, type) fr30_va_arg (tree valist, tree type)
tree valist;
tree type;
{ {
HOST_WIDE_INT size; HOST_WIDE_INT size;
...@@ -803,9 +784,7 @@ fr30_va_arg (valist, type) ...@@ -803,9 +784,7 @@ fr30_va_arg (valist, type)
/* Returns true if OPERAND is an integer value suitable for use in /* Returns true if OPERAND is an integer value suitable for use in
an ADDSP instruction. */ an ADDSP instruction. */
int int
stack_add_operand (operand, mode) stack_add_operand (rtx operand, Mmode mode ATTRIBUTE_UNUSED)
rtx operand;
Mmode mode ATTRIBUTE_UNUSED;
{ {
return return
(GET_CODE (operand) == CONST_INT (GET_CODE (operand) == CONST_INT
...@@ -817,9 +796,7 @@ stack_add_operand (operand, mode) ...@@ -817,9 +796,7 @@ stack_add_operand (operand, mode)
/* Returns true if OPERAND is an integer value suitable for use in /* Returns true if OPERAND is an integer value suitable for use in
an ADD por ADD2 instruction, or if it is a register. */ an ADD por ADD2 instruction, or if it is a register. */
int int
add_immediate_operand (operand, mode) add_immediate_operand (rtx operand, Mmode mode ATTRIBUTE_UNUSED)
rtx operand;
Mmode mode ATTRIBUTE_UNUSED;
{ {
return return
(GET_CODE (operand) == REG (GET_CODE (operand) == REG
...@@ -830,9 +807,7 @@ add_immediate_operand (operand, mode) ...@@ -830,9 +807,7 @@ add_immediate_operand (operand, mode)
/* Returns true if OPERAND is hard register in the range 8 - 15. */ /* Returns true if OPERAND is hard register in the range 8 - 15. */
int int
high_register_operand (operand, mode) high_register_operand (rtx operand, Mmode mode ATTRIBUTE_UNUSED)
rtx operand;
Mmode mode ATTRIBUTE_UNUSED;
{ {
return return
(GET_CODE (operand) == REG (GET_CODE (operand) == REG
...@@ -842,9 +817,7 @@ high_register_operand (operand, mode) ...@@ -842,9 +817,7 @@ high_register_operand (operand, mode)
/* Returns true if OPERAND is hard register in the range 0 - 7. */ /* Returns true if OPERAND is hard register in the range 0 - 7. */
int int
low_register_operand (operand, mode) low_register_operand (rtx operand, Mmode mode ATTRIBUTE_UNUSED)
rtx operand;
Mmode mode ATTRIBUTE_UNUSED;
{ {
return return
(GET_CODE (operand) == REG (GET_CODE (operand) == REG
...@@ -853,9 +826,7 @@ low_register_operand (operand, mode) ...@@ -853,9 +826,7 @@ low_register_operand (operand, mode)
/* Returns true if OPERAND is suitable for use in a CALL insn. */ /* Returns true if OPERAND is suitable for use in a CALL insn. */
int int
call_operand (operand, mode) call_operand (rtx operand, Mmode mode ATTRIBUTE_UNUSED)
rtx operand;
Mmode mode ATTRIBUTE_UNUSED;
{ {
return (GET_CODE (operand) == MEM return (GET_CODE (operand) == MEM
&& (GET_CODE (XEXP (operand, 0)) == SYMBOL_REF && (GET_CODE (XEXP (operand, 0)) == SYMBOL_REF
...@@ -864,9 +835,7 @@ call_operand (operand, mode) ...@@ -864,9 +835,7 @@ call_operand (operand, mode)
/* Returns TRUE if OP is a valid operand of a DImode operation. */ /* Returns TRUE if OP is a valid operand of a DImode operation. */
int int
di_operand (op, mode) di_operand (rtx op, Mmode mode)
rtx op;
Mmode mode;
{ {
if (register_operand (op, mode)) if (register_operand (op, mode))
return TRUE; return TRUE;
...@@ -893,9 +862,7 @@ di_operand (op, mode) ...@@ -893,9 +862,7 @@ di_operand (op, mode)
/* Returns TRUE if OP is a DImode register or MEM. */ /* Returns TRUE if OP is a DImode register or MEM. */
int int
nonimmediate_di_operand (op, mode) nonimmediate_di_operand (rtx op, Mmode mode)
rtx op;
Mmode mode;
{ {
if (register_operand (op, mode)) if (register_operand (op, mode))
return TRUE; return TRUE;
...@@ -915,10 +882,7 @@ nonimmediate_di_operand (op, mode) ...@@ -915,10 +882,7 @@ nonimmediate_di_operand (op, mode)
/* Returns true iff all the registers in the operands array /* Returns true iff all the registers in the operands array
are in descending or ascending order. */ are in descending or ascending order. */
int int
fr30_check_multiple_regs (operands, num_operands, descending) fr30_check_multiple_regs (rtx *operands, int num_operands, int descending)
rtx * operands;
int num_operands;
int descending;
{ {
if (descending) if (descending)
{ {
...@@ -955,8 +919,7 @@ fr30_check_multiple_regs (operands, num_operands, descending) ...@@ -955,8 +919,7 @@ fr30_check_multiple_regs (operands, num_operands, descending)
} }
int int
fr30_const_double_is_zero (operand) fr30_const_double_is_zero (rtx operand)
rtx operand;
{ {
REAL_VALUE_TYPE d; REAL_VALUE_TYPE d;
...@@ -979,8 +942,7 @@ fr30_const_double_is_zero (operand) ...@@ -979,8 +942,7 @@ fr30_const_double_is_zero (operand)
before we can use it. */ before we can use it. */
rtx rtx
fr30_move_double (operands) fr30_move_double (rtx * operands)
rtx * operands;
{ {
rtx src = operands[1]; rtx src = operands[1];
rtx dest = operands[0]; rtx dest = operands[0];
......
...@@ -143,8 +143,7 @@ int ip2k_reorg_merge_qimode = 0; ...@@ -143,8 +143,7 @@ int ip2k_reorg_merge_qimode = 0;
/* Set up local allocation order. */ /* Set up local allocation order. */
void void
ip2k_init_local_alloc (rao) ip2k_init_local_alloc (int *rao)
int * rao;
{ {
static const int alloc_order[] = REG_ALLOC_ORDER; static const int alloc_order[] = REG_ALLOC_ORDER;
...@@ -159,10 +158,7 @@ ip2k_init_local_alloc (rao) ...@@ -159,10 +158,7 @@ ip2k_init_local_alloc (rao)
SIZE is the number of bytes of arguments passed on the stack. */ SIZE is the number of bytes of arguments passed on the stack. */
int int
ip2k_return_pops_args (fundecl, funtype, size) ip2k_return_pops_args (tree fundecl ATTRIBUTE_UNUSED, tree funtype, int size)
tree fundecl ATTRIBUTE_UNUSED;
tree funtype;
int size;
{ {
if (TREE_CODE (funtype) == IDENTIFIER_NODE) if (TREE_CODE (funtype) == IDENTIFIER_NODE)
return size; return size;
...@@ -177,8 +173,7 @@ ip2k_return_pops_args (fundecl, funtype, size) ...@@ -177,8 +173,7 @@ ip2k_return_pops_args (fundecl, funtype, size)
/* Return nonzero if FUNC is a naked function. */ /* Return nonzero if FUNC is a naked function. */
static int static int
ip2k_naked_function_p (func) ip2k_naked_function_p (tree func)
tree func;
{ {
tree a; tree a;
...@@ -191,9 +186,7 @@ ip2k_naked_function_p (func) ...@@ -191,9 +186,7 @@ ip2k_naked_function_p (func)
/* Output function prologue. */ /* Output function prologue. */
void void
function_prologue (file, size) function_prologue (FILE *file, HOST_WIDE_INT size)
FILE *file;
HOST_WIDE_INT size;
{ {
int leaf_func_p; int leaf_func_p;
int main_p; int main_p;
...@@ -314,9 +307,7 @@ function_prologue (file, size) ...@@ -314,9 +307,7 @@ function_prologue (file, size)
/* Output function epilogue. */ /* Output function epilogue. */
void void
function_epilogue (file, size) function_epilogue (FILE *file, HOST_WIDE_INT size)
FILE *file;
HOST_WIDE_INT size;
{ {
int leaf_func_p; int leaf_func_p;
int reg,savelimit; int reg,savelimit;
...@@ -550,9 +541,7 @@ function_epilogue (file, size) ...@@ -550,9 +541,7 @@ function_epilogue (file, size)
STACK ALLOCATION STACK ALLOCATION
<------ SP ($6:$7) */ <------ SP ($6:$7) */
int int
ip2k_init_elim_offset (from, to) ip2k_init_elim_offset (int from, int to)
int from;
int to;
{ {
int leaf_func_p = leaf_function_p (); int leaf_func_p = leaf_function_p ();
int no_saved_pc = leaf_func_p int no_saved_pc = leaf_func_p
...@@ -597,10 +586,7 @@ ip2k_init_elim_offset (from, to) ...@@ -597,10 +586,7 @@ ip2k_init_elim_offset (from, to)
machine for a memory operand of mode MODE. */ machine for a memory operand of mode MODE. */
int int
legitimate_address_p (mode, x, strict) legitimate_address_p (enum machine_mode mode, rtx x, int strict)
enum machine_mode mode;
rtx x;
int strict;
{ {
int off; int off;
...@@ -689,8 +675,7 @@ legitimate_address_p (mode, x, strict) ...@@ -689,8 +675,7 @@ legitimate_address_p (mode, x, strict)
/* Is ADDR mode dependent? */ /* Is ADDR mode dependent? */
int int
ip2k_mode_dependent_address (addr) ip2k_mode_dependent_address (rtx addr)
rtx addr;
{ {
switch (GET_CODE (addr)) switch (GET_CODE (addr))
{ {
...@@ -712,11 +697,8 @@ ip2k_mode_dependent_address (addr) ...@@ -712,11 +697,8 @@ ip2k_mode_dependent_address (addr)
memory address for an operand of mode MODE. */ memory address for an operand of mode MODE. */
rtx rtx
legitimize_address (x, oldx, mode, scratch) legitimize_address (rtx x, rtx oldx ATTRIBUTE_UNUSED,
rtx x; enum machine_mode mode ATTRIBUTE_UNUSED, rtx scratch)
rtx oldx ATTRIBUTE_UNUSED;
rtx scratch;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
rtx reg; rtx reg;
...@@ -747,8 +729,7 @@ legitimize_address (x, oldx, mode, scratch) ...@@ -747,8 +729,7 @@ legitimize_address (x, oldx, mode, scratch)
data and stack variables reside in data memory. Only code is believed data and stack variables reside in data memory. Only code is believed
to be in PRAM or FLASH. */ to be in PRAM or FLASH. */
int int
is_regfile_address (x) is_regfile_address (rtx x)
rtx x;
{ {
while (1) while (1)
switch (GET_CODE (x)) switch (GET_CODE (x))
...@@ -775,9 +756,7 @@ is_regfile_address (x) ...@@ -775,9 +756,7 @@ is_regfile_address (x)
/* Output ADDR to FILE as address. */ /* Output ADDR to FILE as address. */
void void
print_operand_address (file, addr) print_operand_address (FILE *file, rtx addr)
FILE *file;
rtx addr;
{ {
switch (GET_CODE (addr)) switch (GET_CODE (addr))
{ {
...@@ -848,10 +827,7 @@ print_operand_address (file, addr) ...@@ -848,10 +827,7 @@ print_operand_address (file, addr)
/* Output X as assembler operand to file FILE. */ /* Output X as assembler operand to file FILE. */
void void
print_operand (file, x, code) print_operand (FILE *file, rtx x, int code)
FILE *file;
rtx x;
int code;
{ {
int abcd = 0; int abcd = 0;
unsigned long value; unsigned long value;
...@@ -1101,9 +1077,7 @@ print_operand (file, x, code) ...@@ -1101,9 +1077,7 @@ print_operand (file, x, code)
/* Remember the operands for the compare. */ /* Remember the operands for the compare. */
const char * const char *
ip2k_set_compare (x, y) ip2k_set_compare (rtx x, rtx y)
rtx x;
rtx y;
{ {
ip2k_compare_operands[0] = x; ip2k_compare_operands[0] = x;
ip2k_compare_operands[1] = y; ip2k_compare_operands[1] = y;
...@@ -1112,10 +1086,7 @@ ip2k_set_compare (x, y) ...@@ -1112,10 +1086,7 @@ ip2k_set_compare (x, y)
/* Emit the code for sCOND instructions. */ /* Emit the code for sCOND instructions. */
const char * const char *
ip2k_gen_sCOND (insn, code, dest) ip2k_gen_sCOND (rtx insn ATTRIBUTE_UNUSED, enum rtx_code code, rtx dest)
rtx insn ATTRIBUTE_UNUSED;
enum rtx_code code;
rtx dest;
{ {
#define operands ip2k_compare_operands #define operands ip2k_compare_operands
enum machine_mode mode; enum machine_mode mode;
...@@ -1326,10 +1297,7 @@ ip2k_gen_sCOND (insn, code, dest) ...@@ -1326,10 +1297,7 @@ ip2k_gen_sCOND (insn, code, dest)
} }
const char * const char *
ip2k_gen_signed_comp_branch (insn, code, label) ip2k_gen_signed_comp_branch (rtx insn, enum rtx_code code, rtx label)
rtx insn;
enum rtx_code code;
rtx label;
{ {
#define operands ip2k_compare_operands #define operands ip2k_compare_operands
enum machine_mode mode; enum machine_mode mode;
...@@ -1675,10 +1643,7 @@ ip2k_gen_signed_comp_branch (insn, code, label) ...@@ -1675,10 +1643,7 @@ ip2k_gen_signed_comp_branch (insn, code, label)
} }
const char * const char *
ip2k_gen_unsigned_comp_branch (insn, code, label) ip2k_gen_unsigned_comp_branch (rtx insn, enum rtx_code code, rtx label)
rtx insn;
enum rtx_code code;
rtx label;
{ {
#define operands ip2k_compare_operands #define operands ip2k_compare_operands
enum machine_mode mode; enum machine_mode mode;
...@@ -3043,9 +3008,7 @@ ip2k_gen_unsigned_comp_branch (insn, code, label) ...@@ -3043,9 +3008,7 @@ ip2k_gen_unsigned_comp_branch (insn, code, label)
/* Output rtx VALUE as .byte to file FILE. */ /* Output rtx VALUE as .byte to file FILE. */
void void
asm_output_char(file, value) asm_output_char (FILE *file, rtx value)
FILE *file;
rtx value;
{ {
fprintf (file, "\t.byte "); fprintf (file, "\t.byte ");
output_addr_const (file, value); output_addr_const (file, value);
...@@ -3056,9 +3019,7 @@ asm_output_char(file, value) ...@@ -3056,9 +3019,7 @@ asm_output_char(file, value)
/* Output VALUE as .byte to file FILE. */ /* Output VALUE as .byte to file FILE. */
void void
asm_output_byte (file,value) asm_output_byte (FILE *file, int value)
FILE *file;
int value;
{ {
fprintf (file, "\t.byte 0x%x\n",value & 0xff); fprintf (file, "\t.byte 0x%x\n",value & 0xff);
} }
...@@ -3067,9 +3028,7 @@ asm_output_byte (file,value) ...@@ -3067,9 +3028,7 @@ asm_output_byte (file,value)
/* Output rtx VALUE as .word to file FILE. */ /* Output rtx VALUE as .word to file FILE. */
void void
asm_output_short (file, value) asm_output_short (FILE *file, rtx value)
FILE *file;
rtx value;
{ {
fprintf (file, "\t.word "); fprintf (file, "\t.word ");
output_addr_const (file, (value)); output_addr_const (file, (value));
...@@ -3080,9 +3039,7 @@ asm_output_short (file, value) ...@@ -3080,9 +3039,7 @@ asm_output_short (file, value)
/* Output real N to file FILE. */ /* Output real N to file FILE. */
void void
asm_output_float (file, n) asm_output_float (FILE *file, REAL_VALUE_TYPE n)
FILE *file;
REAL_VALUE_TYPE n;
{ {
long val; long val;
char dstr[100]; char dstr[100];
...@@ -3096,9 +3053,7 @@ asm_output_float (file, n) ...@@ -3096,9 +3053,7 @@ asm_output_float (file, n)
/* Sets section name for declaration DECL. */ /* Sets section name for declaration DECL. */
void void
unique_section (decl, reloc) unique_section (tree decl, int reloc ATTRIBUTE_UNUSED)
tree decl;
int reloc ATTRIBUTE_UNUSED;
{ {
int len; int len;
const char *name; const char *name;
...@@ -3131,11 +3086,8 @@ unique_section (decl, reloc) ...@@ -3131,11 +3086,8 @@ unique_section (decl, reloc)
/* Output section name to file FILE. */ /* Output section name to file FILE. */
void void
asm_output_section_name(file, decl, name, reloc) asm_output_section_name (FILE *file, tree decl ATTRIBUTE_UNUSED,
FILE *file; const char *name, int reloc ATTRIBUTE_UNUSED)
tree decl ATTRIBUTE_UNUSED;
const char *name;
int reloc ATTRIBUTE_UNUSED;
{ {
fprintf (file, ".section %s\n", name); fprintf (file, ".section %s\n", name);
} }
...@@ -3145,8 +3097,7 @@ asm_output_section_name(file, decl, name, reloc) ...@@ -3145,8 +3097,7 @@ asm_output_section_name(file, decl, name, reloc)
because registers of CLASS are needed for spill registers. */ because registers of CLASS are needed for spill registers. */
enum reg_class enum reg_class
class_likely_spilled_p(c) class_likely_spilled_p (int c)
int c;
{ {
return (c == IP_REGS return (c == IP_REGS
|| c == IPL_REGS || c == IPL_REGS
...@@ -3176,12 +3127,10 @@ const struct attribute_spec ip2k_attribute_table[] = ...@@ -3176,12 +3127,10 @@ const struct attribute_spec ip2k_attribute_table[] =
/* Handle a "progmem" attribute; arguments as in /* Handle a "progmem" attribute; arguments as in
struct attribute_spec.handler. */ struct attribute_spec.handler. */
static tree static tree
ip2k_handle_progmem_attribute (node, name, args, flags, no_add_attrs) ip2k_handle_progmem_attribute (tree *node, tree name,
tree *node; tree args ATTRIBUTE_UNUSED,
tree name; int flags ATTRIBUTE_UNUSED,
tree args ATTRIBUTE_UNUSED; bool *no_add_attrs)
int flags ATTRIBUTE_UNUSED;
bool *no_add_attrs;
{ {
if (DECL_P (*node)) if (DECL_P (*node))
{ {
...@@ -3220,12 +3169,10 @@ ip2k_handle_progmem_attribute (node, name, args, flags, no_add_attrs) ...@@ -3220,12 +3169,10 @@ ip2k_handle_progmem_attribute (node, name, args, flags, no_add_attrs)
/* Handle an attribute requiring a FUNCTION_DECL; arguments as in /* Handle an attribute requiring a FUNCTION_DECL; arguments as in
struct attribute_spec.handler. */ struct attribute_spec.handler. */
static tree static tree
ip2k_handle_fndecl_attribute (node, name, args, flags, no_add_attrs) ip2k_handle_fndecl_attribute (tree *node, tree name,
tree *node; tree args ATTRIBUTE_UNUSED,
tree name; int flags ATTRIBUTE_UNUSED,
tree args ATTRIBUTE_UNUSED; bool *no_add_attrs)
int flags ATTRIBUTE_UNUSED;
bool *no_add_attrs;
{ {
if (TREE_CODE (*node) != FUNCTION_DECL) if (TREE_CODE (*node) != FUNCTION_DECL)
{ {
...@@ -3244,10 +3191,7 @@ ip2k_handle_fndecl_attribute (node, name, args, flags, no_add_attrs) ...@@ -3244,10 +3191,7 @@ ip2k_handle_fndecl_attribute (node, name, args, flags, no_add_attrs)
scanned. In either case, *TOTAL contains the cost result. */ scanned. In either case, *TOTAL contains the cost result. */
static bool static bool
ip2k_rtx_costs (x, code, outer_code, total) ip2k_rtx_costs (rtx x, int code, int outer_code, int *total)
rtx x;
int code, outer_code;
int *total;
{ {
enum machine_mode mode = GET_MODE (x); enum machine_mode mode = GET_MODE (x);
int extra_cost = 0; int extra_cost = 0;
...@@ -3380,8 +3324,7 @@ ip2k_rtx_costs (x, code, outer_code, total) ...@@ -3380,8 +3324,7 @@ ip2k_rtx_costs (x, code, outer_code, total)
/* Calculate the cost of a memory address. */ /* Calculate the cost of a memory address. */
static int static int
ip2k_address_cost (x) ip2k_address_cost (rtx x)
rtx x;
{ {
switch (legitimate_address_p (VOIDmode, x, 0)) switch (legitimate_address_p (VOIDmode, x, 0))
{ {
...@@ -4160,9 +4103,7 @@ mdr_try_move_dp_reload (first_insn) ...@@ -4160,9 +4103,7 @@ mdr_try_move_dp_reload (first_insn)
a fixed constant, offset. If it definitely can then returns nonzero. */ a fixed constant, offset. If it definitely can then returns nonzero. */
static int static int
ip2k_check_can_adjust_stack_ref (x, offset) ip2k_check_can_adjust_stack_ref (rtx x, int offset)
rtx x;
int offset;
{ {
if (GET_RTX_CLASS (GET_CODE (x)) == '2' if (GET_RTX_CLASS (GET_CODE (x)) == '2'
|| GET_RTX_CLASS (GET_CODE (x)) == 'c') || GET_RTX_CLASS (GET_CODE (x)) == 'c')
...@@ -4208,9 +4149,7 @@ ip2k_check_can_adjust_stack_ref (x, offset) ...@@ -4208,9 +4149,7 @@ ip2k_check_can_adjust_stack_ref (x, offset)
a fixed offset. */ a fixed offset. */
static void static void
ip2k_adjust_stack_ref (x, offset) ip2k_adjust_stack_ref (rtx *x, int offset)
rtx *x;
int offset;
{ {
if (GET_RTX_CLASS (GET_CODE (*x)) == '2' if (GET_RTX_CLASS (GET_CODE (*x)) == '2'
|| GET_RTX_CLASS (GET_CODE (*x)) == 'c') || GET_RTX_CLASS (GET_CODE (*x)) == 'c')
...@@ -4699,9 +4638,7 @@ mdr_try_propagate_clr (first_insn) ...@@ -4699,9 +4638,7 @@ mdr_try_propagate_clr (first_insn)
nonzero if we definitely don't have such a memory ref. */ nonzero if we definitely don't have such a memory ref. */
static int static int
ip2k_xexp_not_uses_reg_for_mem (x, regno) ip2k_xexp_not_uses_reg_for_mem (rtx x, unsigned int regno)
rtx x;
unsigned int regno;
{ {
if (regno & 1) if (regno & 1)
regno &= 0xfffffffe; regno &= 0xfffffffe;
...@@ -5316,7 +5253,7 @@ mdr_try_wreg_elim (first_insn) ...@@ -5316,7 +5253,7 @@ mdr_try_wreg_elim (first_insn)
making the subsequent runs continue to win. */ making the subsequent runs continue to win. */
static void static void
ip2k_reorg () ip2k_reorg (void)
{ {
#ifdef IP2K_MD_REORG_PASS #ifdef IP2K_MD_REORG_PASS
rtx first_insn, insn, set; rtx first_insn, insn, set;
...@@ -5518,8 +5455,7 @@ ip2k_init_libfuncs (void) ...@@ -5518,8 +5455,7 @@ ip2k_init_libfuncs (void)
/* Returns a bit position if mask contains only a single bit. Returns -1 if /* Returns a bit position if mask contains only a single bit. Returns -1 if
there were zero or more than one set bits. */ there were zero or more than one set bits. */
int int
find_one_set_bit_p (mask) find_one_set_bit_p (HOST_WIDE_INT mask)
HOST_WIDE_INT mask;
{ {
int i; int i;
unsigned HOST_WIDE_INT n = mask; unsigned HOST_WIDE_INT n = mask;
...@@ -5540,8 +5476,7 @@ find_one_set_bit_p (mask) ...@@ -5540,8 +5476,7 @@ find_one_set_bit_p (mask)
/* Returns a bit position if mask contains only a single clear bit. /* Returns a bit position if mask contains only a single clear bit.
Returns -1 if there were zero or more than one clear bits. */ Returns -1 if there were zero or more than one clear bits. */
int int
find_one_clear_bit_p (mask) find_one_clear_bit_p (HOST_WIDE_INT mask)
HOST_WIDE_INT mask;
{ {
int i; int i;
unsigned HOST_WIDE_INT n = mask; unsigned HOST_WIDE_INT n = mask;
...@@ -5568,10 +5503,8 @@ find_one_clear_bit_p (mask) ...@@ -5568,10 +5503,8 @@ find_one_clear_bit_p (mask)
and OPERANDS[5]. */ and OPERANDS[5]. */
void void
ip2k_split_words (nmode, omode, operands) ip2k_split_words (enum machine_mode nmode, enum machine_mode omode,
enum machine_mode nmode; rtx *operands)
enum machine_mode omode;
rtx *operands;
{ {
rtx dl, dh; /* src/dest pieces. */ rtx dl, dh; /* src/dest pieces. */
rtx sl, sh; rtx sl, sh;
...@@ -5759,9 +5692,7 @@ ip2k_split_words (nmode, omode, operands) ...@@ -5759,9 +5692,7 @@ ip2k_split_words (nmode, omode, operands)
/* Get the low half of an operand. */ /* Get the low half of an operand. */
rtx rtx
ip2k_get_low_half (x, mode) ip2k_get_low_half (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
switch (GET_CODE (x)) switch (GET_CODE (x))
{ {
...@@ -5860,9 +5791,7 @@ ip2k_get_low_half (x, mode) ...@@ -5860,9 +5791,7 @@ ip2k_get_low_half (x, mode)
/* Get the high half of an operand. */ /* Get the high half of an operand. */
rtx rtx
ip2k_get_high_half (x, mode) ip2k_get_high_half (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
switch (GET_CODE (x)) switch (GET_CODE (x))
{ {
...@@ -5962,9 +5891,7 @@ ip2k_get_high_half (x, mode) ...@@ -5962,9 +5891,7 @@ ip2k_get_high_half (x, mode)
or REG_FP. */ or REG_FP. */
int int
ip2k_address_uses_reg_p (x, r) ip2k_address_uses_reg_p (rtx x, unsigned int r)
rtx x;
unsigned int r;
{ {
if (GET_CODE (x) != MEM) if (GET_CODE (x) != MEM)
return 0; return 0;
...@@ -6011,10 +5938,7 @@ ip2k_address_uses_reg_p (x, r) ...@@ -6011,10 +5938,7 @@ ip2k_address_uses_reg_p (x, r)
that it doesn't then we return TRUE otherwise we assume FALSE. */ that it doesn't then we return TRUE otherwise we assume FALSE. */
int int
ip2k_xexp_not_uses_reg_p (x, r, rsz) ip2k_xexp_not_uses_reg_p (rtx x, unsigned int r, int rsz)
rtx x;
unsigned int r;
int rsz;
{ {
switch (GET_CODE (x)) switch (GET_CODE (x))
{ {
...@@ -6047,10 +5971,7 @@ ip2k_xexp_not_uses_reg_p (x, r, rsz) ...@@ -6047,10 +5971,7 @@ ip2k_xexp_not_uses_reg_p (x, r, rsz)
that it doesn't then we return TRUE otherwise we assume FALSE. */ that it doesn't then we return TRUE otherwise we assume FALSE. */
int int
ip2k_composite_xexp_not_uses_reg_p (x, r, rsz) ip2k_composite_xexp_not_uses_reg_p (rtx x, unsigned int r, int rsz)
rtx x;
unsigned int r;
int rsz;
{ {
if (GET_RTX_CLASS (GET_CODE (x)) == 'b') if (GET_RTX_CLASS (GET_CODE (x)) == 'b')
return (ip2k_composite_xexp_not_uses_reg_p (XEXP (x, 0), r, rsz) return (ip2k_composite_xexp_not_uses_reg_p (XEXP (x, 0), r, rsz)
...@@ -6074,8 +5995,7 @@ ip2k_composite_xexp_not_uses_reg_p (x, r, rsz) ...@@ -6074,8 +5995,7 @@ ip2k_composite_xexp_not_uses_reg_p (x, r, rsz)
it doesn't then we return TRUE otherwise we assume FALSE. */ it doesn't then we return TRUE otherwise we assume FALSE. */
int int
ip2k_composite_xexp_not_uses_cc0_p (x) ip2k_composite_xexp_not_uses_cc0_p (rtx x)
rtx x;
{ {
if (GET_RTX_CLASS (GET_CODE (x)) == 'b') if (GET_RTX_CLASS (GET_CODE (x)) == 'b')
return (ip2k_composite_xexp_not_uses_cc0_p (XEXP (x, 0)) return (ip2k_composite_xexp_not_uses_cc0_p (XEXP (x, 0))
...@@ -6096,17 +6016,13 @@ ip2k_composite_xexp_not_uses_cc0_p (x) ...@@ -6096,17 +6016,13 @@ ip2k_composite_xexp_not_uses_cc0_p (x)
} }
int int
ip2k_split_dest_operand (x, mode) ip2k_split_dest_operand (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
return nonimmediate_operand (x, mode) || push_operand (x, mode); return nonimmediate_operand (x, mode) || push_operand (x, mode);
} }
int int
ip2k_nonptr_operand (x, mode) ip2k_nonptr_operand (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
return register_operand (x, mode) && !ip2k_ptr_operand (x, mode); return register_operand (x, mode) && !ip2k_ptr_operand (x, mode);
} }
...@@ -6114,9 +6030,7 @@ ip2k_nonptr_operand (x, mode) ...@@ -6114,9 +6030,7 @@ ip2k_nonptr_operand (x, mode)
/* Is X a reference to IP or DP or SP? */ /* Is X a reference to IP or DP or SP? */
int int
ip2k_ptr_operand (x, mode) ip2k_ptr_operand (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
if (GET_CODE (x) == SUBREG) if (GET_CODE (x) == SUBREG)
...@@ -6130,18 +6044,14 @@ ip2k_ptr_operand (x, mode) ...@@ -6130,18 +6044,14 @@ ip2k_ptr_operand (x, mode)
} }
int int
ip2k_sp_operand (x, mode) ip2k_sp_operand (rtx x, enum machine_mode mode ATTRIBUTE_UNUSED)
rtx x;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
return REG_P (x) && REGNO (x) == REG_SP; return REG_P (x) && REGNO (x) == REG_SP;
} }
int int
ip2k_ip_operand (x, mode) ip2k_ip_operand (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
if (GET_CODE (x) != MEM) if (GET_CODE (x) != MEM)
...@@ -6163,9 +6073,7 @@ ip2k_ip_operand (x, mode) ...@@ -6163,9 +6073,7 @@ ip2k_ip_operand (x, mode)
/* Is X a memory address suitable for SP or DP relative addressing? */ /* Is X a memory address suitable for SP or DP relative addressing? */
int int
ip2k_short_operand (x, mode) ip2k_short_operand (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
int r; int r;
unsigned int offs = 0; unsigned int offs = 0;
...@@ -6211,9 +6119,7 @@ ip2k_short_operand (x, mode) ...@@ -6211,9 +6119,7 @@ ip2k_short_operand (x, mode)
} }
int int
ip2k_nonsp_reg_operand (x, mode) ip2k_nonsp_reg_operand (rtx x, enum machine_mode mode ATTRIBUTE_UNUSED)
rtx x;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
if (GET_CODE (x) == SUBREG) if (GET_CODE (x) == SUBREG)
x = SUBREG_REG (x); x = SUBREG_REG (x);
...@@ -6222,9 +6128,7 @@ ip2k_nonsp_reg_operand (x, mode) ...@@ -6222,9 +6128,7 @@ ip2k_nonsp_reg_operand (x, mode)
} }
int int
ip2k_gen_operand (x, mode) ip2k_gen_operand (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
return ip2k_short_operand (x, mode) return ip2k_short_operand (x, mode)
|| (GET_CODE (x) == SUBREG || (GET_CODE (x) == SUBREG
...@@ -6233,9 +6137,7 @@ ip2k_gen_operand (x, mode) ...@@ -6233,9 +6137,7 @@ ip2k_gen_operand (x, mode)
} }
int int
ip2k_extra_constraint (x, c) ip2k_extra_constraint (rtx x, int c)
rtx x;
int c;
{ {
switch (c) switch (c)
{ {
...@@ -6254,18 +6156,14 @@ ip2k_extra_constraint (x, c) ...@@ -6254,18 +6156,14 @@ ip2k_extra_constraint (x, c)
} }
int int
ip2k_unary_operator (op, mode) ip2k_unary_operator (rtx op, enum machine_mode mode)
rtx op;
enum machine_mode mode;
{ {
return ((mode == VOIDmode || GET_MODE (op) == mode) return ((mode == VOIDmode || GET_MODE (op) == mode)
&& GET_RTX_CLASS (GET_CODE (op)) == '1'); && GET_RTX_CLASS (GET_CODE (op)) == '1');
} }
int int
ip2k_binary_operator (op, mode) ip2k_binary_operator (rtx op, enum machine_mode mode)
rtx op;
enum machine_mode mode;
{ {
return ((mode == VOIDmode || GET_MODE (op) == mode) return ((mode == VOIDmode || GET_MODE (op) == mode)
&& (GET_RTX_CLASS (GET_CODE (op)) == 'c' && (GET_RTX_CLASS (GET_CODE (op)) == 'c'
...@@ -6273,9 +6171,7 @@ ip2k_binary_operator (op, mode) ...@@ -6273,9 +6171,7 @@ ip2k_binary_operator (op, mode)
} }
int int
ip2k_symbol_ref_operand (op, mode) ip2k_symbol_ref_operand (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
rtx op;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
/* We define an IP2k symbol ref to be either a direct reference or one /* We define an IP2k symbol ref to be either a direct reference or one
with a constant offset. */ with a constant offset. */
...@@ -6286,18 +6182,14 @@ ip2k_symbol_ref_operand (op, mode) ...@@ -6286,18 +6182,14 @@ ip2k_symbol_ref_operand (op, mode)
} }
int int
ip2k_signed_comparison_operator (op, mode) ip2k_signed_comparison_operator (rtx op, enum machine_mode mode)
rtx op;
enum machine_mode mode;
{ {
return (comparison_operator (op, mode) return (comparison_operator (op, mode)
&& signed_condition (GET_CODE (op)) == GET_CODE (op)); && signed_condition (GET_CODE (op)) == GET_CODE (op));
} }
int int
ip2k_unsigned_comparison_operator (op, mode) ip2k_unsigned_comparison_operator (rtx op, enum machine_mode mode)
rtx op;
enum machine_mode mode;
{ {
return (comparison_operator (op, mode) return (comparison_operator (op, mode)
&& unsigned_condition (GET_CODE (op)) == GET_CODE (op)); && unsigned_condition (GET_CODE (op)) == GET_CODE (op));
......
...@@ -92,7 +92,7 @@ static void mn10300_encode_section_info (tree, rtx, int); ...@@ -92,7 +92,7 @@ static void mn10300_encode_section_info (tree, rtx, int);
struct gcc_target targetm = TARGET_INITIALIZER; struct gcc_target targetm = TARGET_INITIALIZER;
static void static void
mn10300_file_start () mn10300_file_start (void)
{ {
default_file_start (); default_file_start ();
...@@ -107,10 +107,7 @@ mn10300_file_start () ...@@ -107,10 +107,7 @@ mn10300_file_start ()
FILE. */ FILE. */
void void
print_operand (file, x, code) print_operand (FILE *file, rtx x, int code)
FILE *file;
rtx x;
int code;
{ {
switch (code) switch (code)
{ {
...@@ -437,9 +434,7 @@ print_operand (file, x, code) ...@@ -437,9 +434,7 @@ print_operand (file, x, code)
/* Output assembly language output for the address ADDR to FILE. */ /* Output assembly language output for the address ADDR to FILE. */
void void
print_operand_address (file, addr) print_operand_address (FILE *file, rtx addr)
FILE *file;
rtx addr;
{ {
switch (GET_CODE (addr)) switch (GET_CODE (addr))
{ {
...@@ -477,7 +472,7 @@ print_operand_address (file, addr) ...@@ -477,7 +472,7 @@ print_operand_address (file, addr)
/* Count the number of FP registers that have to be saved. */ /* Count the number of FP registers that have to be saved. */
static int static int
fp_regs_to_save () fp_regs_to_save (void)
{ {
int i, n = 0; int i, n = 0;
...@@ -498,9 +493,7 @@ fp_regs_to_save () ...@@ -498,9 +493,7 @@ fp_regs_to_save ()
bits 14 to 17 must have the same value. */ bits 14 to 17 must have the same value. */
void void
mn10300_print_reg_list (file, mask) mn10300_print_reg_list (FILE *file, int mask)
FILE *file;
int mask;
{ {
int need_comma; int need_comma;
int i; int i;
...@@ -531,7 +524,7 @@ mn10300_print_reg_list (file, mask) ...@@ -531,7 +524,7 @@ mn10300_print_reg_list (file, mask)
} }
int int
can_use_return_insn () can_use_return_insn (void)
{ {
/* size includes the fixed stack space needed for function calls. */ /* size includes the fixed stack space needed for function calls. */
int size = get_frame_size () + current_function_outgoing_args_size; int size = get_frame_size () + current_function_outgoing_args_size;
...@@ -558,7 +551,7 @@ can_use_return_insn () ...@@ -558,7 +551,7 @@ can_use_return_insn ()
all of them will be included in the mask if any one of them is used. */ all of them will be included in the mask if any one of them is used. */
int int
mn10300_get_live_callee_saved_regs () mn10300_get_live_callee_saved_regs (void)
{ {
int mask; int mask;
int i; int i;
...@@ -593,8 +586,7 @@ mn10300_get_live_callee_saved_regs () ...@@ -593,8 +586,7 @@ mn10300_get_live_callee_saved_regs ()
(reg:SI R1))) */ (reg:SI R1))) */
void void
mn10300_gen_multiple_store (mask) mn10300_gen_multiple_store (int mask)
int mask;
{ {
if (mask != 0) if (mask != 0)
{ {
...@@ -642,7 +634,7 @@ mn10300_gen_multiple_store (mask) ...@@ -642,7 +634,7 @@ mn10300_gen_multiple_store (mask)
} }
void void
expand_prologue () expand_prologue (void)
{ {
HOST_WIDE_INT size; HOST_WIDE_INT size;
...@@ -917,7 +909,7 @@ expand_prologue () ...@@ -917,7 +909,7 @@ expand_prologue ()
} }
void void
expand_epilogue () expand_epilogue (void)
{ {
HOST_WIDE_INT size; HOST_WIDE_INT size;
...@@ -1155,9 +1147,7 @@ expand_epilogue () ...@@ -1155,9 +1147,7 @@ expand_epilogue ()
/* Update the condition code from the insn. */ /* Update the condition code from the insn. */
void void
notice_update_cc (body, insn) notice_update_cc (rtx body, rtx insn)
rtx body;
rtx insn;
{ {
switch (get_attr_cc (insn)) switch (get_attr_cc (insn))
{ {
...@@ -1220,9 +1210,7 @@ notice_update_cc (body, insn) ...@@ -1220,9 +1210,7 @@ notice_update_cc (body, insn)
registers it saves. Return 0 otherwise. */ registers it saves. Return 0 otherwise. */
int int
store_multiple_operation (op, mode) store_multiple_operation (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
rtx op;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
int count; int count;
int mask; int mask;
...@@ -1298,9 +1286,7 @@ store_multiple_operation (op, mode) ...@@ -1298,9 +1286,7 @@ store_multiple_operation (op, mode)
/* Return true if OP is a valid call operand. */ /* Return true if OP is a valid call operand. */
int int
call_address_operand (op, mode) call_address_operand (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
rtx op;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
if (flag_pic) if (flag_pic)
return (EXTRA_CONSTRAINT (op, 'S') || GET_CODE (op) == REG); return (EXTRA_CONSTRAINT (op, 'S') || GET_CODE (op) == REG);
...@@ -1313,10 +1299,7 @@ call_address_operand (op, mode) ...@@ -1313,10 +1299,7 @@ call_address_operand (op, mode)
We might be able to simplify this. */ We might be able to simplify this. */
enum reg_class enum reg_class
secondary_reload_class (class, mode, in) secondary_reload_class (enum reg_class class, enum machine_mode mode, rtx in)
enum reg_class class;
enum machine_mode mode;
rtx in;
{ {
/* Memory loads less than a full word wide can't have an /* Memory loads less than a full word wide can't have an
address or stack pointer destination. They must use address or stack pointer destination. They must use
...@@ -1372,8 +1355,7 @@ secondary_reload_class (class, mode, in) ...@@ -1372,8 +1355,7 @@ secondary_reload_class (class, mode, in)
} }
int int
initial_offset (from, to) initial_offset (int from, int to)
int from, to;
{ {
/* The difference between the argument pointer and the frame pointer /* The difference between the argument pointer and the frame pointer
is the size of the callee register save area. */ is the size of the callee register save area. */
...@@ -1426,7 +1408,7 @@ initial_offset (from, to) ...@@ -1426,7 +1408,7 @@ initial_offset (from, to)
/* Flush the argument registers to the stack for a stdarg function; /* Flush the argument registers to the stack for a stdarg function;
return the new argument pointer. */ return the new argument pointer. */
rtx rtx
mn10300_builtin_saveregs () mn10300_builtin_saveregs (void)
{ {
rtx offset, mem; rtx offset, mem;
tree fntype = TREE_TYPE (current_function_decl); tree fntype = TREE_TYPE (current_function_decl);
...@@ -1456,17 +1438,14 @@ mn10300_builtin_saveregs () ...@@ -1456,17 +1438,14 @@ mn10300_builtin_saveregs ()
} }
void void
mn10300_va_start (valist, nextarg) mn10300_va_start (tree valist, rtx nextarg)
tree valist;
rtx nextarg;
{ {
nextarg = expand_builtin_saveregs (); nextarg = expand_builtin_saveregs ();
std_expand_builtin_va_start (valist, nextarg); std_expand_builtin_va_start (valist, nextarg);
} }
rtx rtx
mn10300_va_arg (valist, type) mn10300_va_arg (tree valist, tree type)
tree valist, type;
{ {
HOST_WIDE_INT align, rsize; HOST_WIDE_INT align, rsize;
tree t, ptr, pptr; tree t, ptr, pptr;
...@@ -1505,11 +1484,8 @@ mn10300_va_arg (valist, type) ...@@ -1505,11 +1484,8 @@ mn10300_va_arg (valist, type)
from a function. If the result is 0, the argument is pushed. */ from a function. If the result is 0, the argument is pushed. */
rtx rtx
function_arg (cum, mode, type, named) function_arg (CUMULATIVE_ARGS *cum, enum machine_mode mode,
CUMULATIVE_ARGS *cum; tree type, int named ATTRIBUTE_UNUSED)
enum machine_mode mode;
tree type;
int named ATTRIBUTE_UNUSED;
{ {
rtx result = 0; rtx result = 0;
int size, align; int size, align;
...@@ -1558,11 +1534,8 @@ function_arg (cum, mode, type, named) ...@@ -1558,11 +1534,8 @@ function_arg (cum, mode, type, named)
in registers and partially in memory. */ in registers and partially in memory. */
int int
function_arg_partial_nregs (cum, mode, type, named) function_arg_partial_nregs (CUMULATIVE_ARGS *cum, enum machine_mode mode,
CUMULATIVE_ARGS *cum; tree type, int named ATTRIBUTE_UNUSED)
enum machine_mode mode;
tree type;
int named ATTRIBUTE_UNUSED;
{ {
int size, align; int size, align;
...@@ -1599,8 +1572,7 @@ function_arg_partial_nregs (cum, mode, type, named) ...@@ -1599,8 +1572,7 @@ function_arg_partial_nregs (cum, mode, type, named)
/* Output a tst insn. */ /* Output a tst insn. */
const char * const char *
output_tst (operand, insn) output_tst (rtx operand, rtx insn)
rtx operand, insn;
{ {
rtx temp; rtx temp;
int past_call = 0; int past_call = 0;
...@@ -1689,9 +1661,7 @@ output_tst (operand, insn) ...@@ -1689,9 +1661,7 @@ output_tst (operand, insn)
} }
int int
impossible_plus_operand (op, mode) impossible_plus_operand (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
rtx op;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
if (GET_CODE (op) != PLUS) if (GET_CODE (op) != PLUS)
return 0; return 0;
...@@ -1707,9 +1677,7 @@ impossible_plus_operand (op, mode) ...@@ -1707,9 +1677,7 @@ impossible_plus_operand (op, mode)
for the btst insn which may examine memory or a register (the memory for the btst insn which may examine memory or a register (the memory
variant only allows an unsigned 8 bit integer). */ variant only allows an unsigned 8 bit integer). */
int int
const_8bit_operand (op, mode) const_8bit_operand (register rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
register rtx op;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
return (GET_CODE (op) == CONST_INT return (GET_CODE (op) == CONST_INT
&& INTVAL (op) >= 0 && INTVAL (op) >= 0
...@@ -1718,9 +1686,7 @@ const_8bit_operand (op, mode) ...@@ -1718,9 +1686,7 @@ const_8bit_operand (op, mode)
/* Return true if the operand is the 1.0f constant. */ /* Return true if the operand is the 1.0f constant. */
int int
const_1f_operand (op, mode) const_1f_operand (register rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
register rtx op;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
return (op == CONST1_RTX (SFmode)); return (op == CONST1_RTX (SFmode));
} }
...@@ -1728,9 +1694,7 @@ const_1f_operand (op, mode) ...@@ -1728,9 +1694,7 @@ const_1f_operand (op, mode)
/* Similarly, but when using a zero_extract pattern for a btst where /* Similarly, but when using a zero_extract pattern for a btst where
the source operand might end up in memory. */ the source operand might end up in memory. */
int int
mask_ok_for_mem_btst (len, bit) mask_ok_for_mem_btst (int len, int bit)
int len;
int bit;
{ {
unsigned int mask = 0; unsigned int mask = 0;
...@@ -1752,9 +1716,7 @@ mask_ok_for_mem_btst (len, bit) ...@@ -1752,9 +1716,7 @@ mask_ok_for_mem_btst (len, bit)
expressions will have one of a few well defined forms, so expressions will have one of a few well defined forms, so
we need only check those forms. */ we need only check those forms. */
int int
symbolic_operand (op, mode) symbolic_operand (register rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
register rtx op;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
switch (GET_CODE (op)) switch (GET_CODE (op))
{ {
...@@ -1787,10 +1749,8 @@ symbolic_operand (op, mode) ...@@ -1787,10 +1749,8 @@ symbolic_operand (op, mode)
But on a few ports with segmented architectures and indexed addressing But on a few ports with segmented architectures and indexed addressing
(mn10300, hppa) it is used to rewrite certain problematical addresses. */ (mn10300, hppa) it is used to rewrite certain problematical addresses. */
rtx rtx
legitimize_address (x, oldx, mode) legitimize_address (rtx x, rtx oldx ATTRIBUTE_UNUSED,
rtx x; enum machine_mode mode ATTRIBUTE_UNUSED)
rtx oldx ATTRIBUTE_UNUSED;
enum machine_mode mode ATTRIBUTE_UNUSED;
{ {
if (flag_pic && ! legitimate_pic_operand_p (x)) if (flag_pic && ! legitimate_pic_operand_p (x))
x = legitimize_pic_address (oldx, NULL_RTX); x = legitimize_pic_address (oldx, NULL_RTX);
...@@ -1828,9 +1788,7 @@ legitimize_address (x, oldx, mode) ...@@ -1828,9 +1788,7 @@ legitimize_address (x, oldx, mode)
/* Convert a non-PIC address in `orig' to a PIC address using @GOT or /* Convert a non-PIC address in `orig' to a PIC address using @GOT or
@GOTOFF in `reg'. */ @GOTOFF in `reg'. */
rtx rtx
legitimize_pic_address (orig, reg) legitimize_pic_address (rtx orig, rtx reg)
rtx orig;
rtx reg;
{ {
if (GET_CODE (orig) == LABEL_REF if (GET_CODE (orig) == LABEL_REF
|| (GET_CODE (orig) == SYMBOL_REF || (GET_CODE (orig) == SYMBOL_REF
...@@ -1857,8 +1815,7 @@ legitimize_pic_address (orig, reg) ...@@ -1857,8 +1815,7 @@ legitimize_pic_address (orig, reg)
/* Return zero if X references a SYMBOL_REF or LABEL_REF whose symbol /* Return zero if X references a SYMBOL_REF or LABEL_REF whose symbol
isn't protected by a PIC unspec; nonzero otherwise. */ isn't protected by a PIC unspec; nonzero otherwise. */
int int
legitimate_pic_operand_p (x) legitimate_pic_operand_p (rtx x)
rtx x;
{ {
register const char *fmt; register const char *fmt;
register int i; register int i;
...@@ -1895,9 +1852,7 @@ legitimate_pic_operand_p (x) ...@@ -1895,9 +1852,7 @@ legitimate_pic_operand_p (x)
} }
static int static int
mn10300_address_cost_1 (x, unsig) mn10300_address_cost_1 (rtx x, int *unsig)
rtx x;
int *unsig;
{ {
switch (GET_CODE (x)) switch (GET_CODE (x))
{ {
...@@ -1976,18 +1931,14 @@ mn10300_address_cost_1 (x, unsig) ...@@ -1976,18 +1931,14 @@ mn10300_address_cost_1 (x, unsig)
} }
static int static int
mn10300_address_cost (x) mn10300_address_cost (rtx x)
rtx x;
{ {
int s = 0; int s = 0;
return mn10300_address_cost_1 (x, &s); return mn10300_address_cost_1 (x, &s);
} }
static bool static bool
mn10300_rtx_costs (x, code, outer_code, total) mn10300_rtx_costs (rtx x, int code, int outer_code, int *total)
rtx x;
int code, outer_code;
int *total;
{ {
switch (code) switch (code)
{ {
...@@ -2039,8 +1990,7 @@ mn10300_rtx_costs (x, code, outer_code, total) ...@@ -2039,8 +1990,7 @@ mn10300_rtx_costs (x, code, outer_code, total)
movdf and movdi. */ movdf and movdi. */
bool bool
mn10300_wide_const_load_uses_clr (operands) mn10300_wide_const_load_uses_clr (rtx operands[2])
rtx operands[2];
{ {
long val[2]; long val[2];
...@@ -2085,10 +2035,7 @@ mn10300_wide_const_load_uses_clr (operands) ...@@ -2085,10 +2035,7 @@ mn10300_wide_const_load_uses_clr (operands)
may access it using GOTOFF instead of GOT. */ may access it using GOTOFF instead of GOT. */
static void static void
mn10300_encode_section_info (decl, rtl, first) mn10300_encode_section_info (tree decl, rtx rtl, int first)
tree decl;
rtx rtl;
int first;
{ {
rtx symbol; rtx symbol;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment