#include "expr.h"
#include "function.h"
#include "recog.h"
+#include "toplev.h"
/* Save the operands last given to a compare for use when we
generate a scc or bcc insn. */
int
m32r_valid_machine_decl_attribute (type, attributes, identifier, args)
- tree type;
- tree attributes;
+ tree type ATTRIBUTE_UNUSED;
+ tree attributes ATTRIBUTE_UNUSED;
tree identifier;
tree args;
{
int
m32r_comp_type_attributes (type1, type2)
- tree type1, type2;
+ tree type1 ATTRIBUTE_UNUSED;
+ tree type2 ATTRIBUTE_UNUSED;
{
return 1;
}
void
m32r_set_default_type_attributes (type)
- tree type;
+ tree type ATTRIBUTE_UNUSED;
{
}
\f
int
symbolic_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
switch (GET_CODE (op))
{
int
small_data_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
if (! TARGET_SDATA_USE)
return 0;
int
addr24_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
if (GET_CODE (op) == LABEL_REF)
return TARGET_ADDR24;
int
call26_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
if (GET_CODE (op) == SYMBOL_REF)
return ! LARGE_NAME_P (XSTR (op, 0));
int
seth_add3_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
if (GET_CODE (op) == SYMBOL_REF
|| GET_CODE (op) == LABEL_REF)
int
cmp_int16_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
if (GET_CODE (op) != CONST_INT)
return 0;
int
uint16_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
if (GET_CODE (op) != CONST_INT)
return 0;
int
two_insn_const_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
if (GET_CODE (op) != CONST_INT)
return 0;
int
eqne_comparison_operator (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
enum rtx_code code = GET_CODE (op);
int
signed_comparison_operator (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
enum rtx_code code = GET_CODE (op);
int
memreg_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
return GET_CODE (op) == MEM && GET_CODE (XEXP (op, 0)) == REG;
}
int
small_insn_p (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
if (GET_CODE (op) == CONST_INT && INTVAL (op) == 0)
return 1;
int
large_insn_p (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
if (GET_RTX_CLASS (GET_CODE (op)) != 'i')
return 0;
int
m32r_select_cc_mode (op, x, y)
- int op;
- rtx x, y;
+ int op ATTRIBUTE_UNUSED;
+ rtx x ATTRIBUTE_UNUSED;
+ rtx y ATTRIBUTE_UNUSED;
{
return (int)SImode;
}
enum machine_mode mode = SELECT_CC_MODE (code, x, y);
enum rtx_code compare_code, branch_code;
rtx cc_reg = gen_rtx_REG (mode, CARRY_REGNUM);
- int swap_p = 0;
+ int must_swap = 0;
switch (code)
{
case LEU: compare_code = LTU; branch_code = EQ; must_swap = 1; break;
case GTU: compare_code = LTU; branch_code = NE; must_swap = 1; break;
case GEU: compare_code = LTU; branch_code = EQ; break;
+
+ default:
+ abort();
}
if (need_compare)
case LTU :
emit_insn (gen_cmp_ltusi_insn (must_swap ? y : x, must_swap ? x : y));
break;
+
+ default:
+ abort ();
}
return gen_rtx (branch_code, VOIDmode, cc_reg, CONST0_RTX (mode));
CUMULATIVE_ARGS *cum;
int int_mode;
tree type;
- int named;
+ int named ATTRIBUTE_UNUSED;
{
enum machine_mode mode = (enum machine_mode)int_mode;
int ret;
int
m32r_address_cost (addr)
- rtx addr;
+ rtx addr ATTRIBUTE_UNUSED;
{
return 1;
}
void
m32r_output_function_epilogue (file, size)
FILE * file;
- int size;
+ int size ATTRIBUTE_UNUSED;
{
int regno;
int noepilogue = FALSE;
if (!noepilogue)
{
- unsigned int pretend_size = current_frame_info.pretend_size;
- unsigned int frame_size = total_size - pretend_size;
unsigned int var_size = current_frame_info.var_size;
unsigned int args_size = current_frame_info.args_size;
unsigned int gmask = current_frame_info.gmask;
void
m32r_initialize_trampoline (tramp, fnaddr, cxt)
- rtx tramp, fnaddr, cxt;
+ rtx tramp ATTRIBUTE_UNUSED;
+ rtx fnaddr ATTRIBUTE_UNUSED;
+ rtx cxt ATTRIBUTE_UNUSED;
{
}
\f
rtx first, second;
split_double (x, &first, &second);
- fprintf (file, "0x%08x",
+ fprintf (file, HOST_WIDE_INT_PRINT_HEX,
code == 'L' ? INTVAL (first) : INTVAL (second));
}
else
int
carry_compare_operand (op, int_mode)
rtx op;
- int int_mode;
+ int int_mode ATTRIBUTE_UNUSED;
{
rtx x;
char *
emit_cond_move (operands, insn)
rtx * operands;
- rtx insn;
+ rtx insn ATTRIBUTE_UNUSED;
{
static char buffer [100];
char * dest = reg_names [REGNO (operands [0])];
char *
m32r_output_block_move (insn, operands)
- rtx insn;
+ rtx insn ATTRIBUTE_UNUSED;
rtx operands[];
{
HOST_WIDE_INT bytes = INTVAL (operands[2]);
int
m32r_block_immediate_operand (op, mode)
rtx op;
- int mode;
+ int mode ATTRIBUTE_UNUSED;
{
if (GET_CODE (op) != CONST_INT
|| INTVAL (op) > MAX_MOVE_BYTES
{ "large_insn_p", { INSN, CALL_INSN, JUMP_INSN }},
/* Functions declared in m32r.c */
-#ifndef PROTO
-#if defined (USE_PROTOTYPES) ? USE_PROTOTYPES : defined (__STDC__)
-#define PROTO(ARGS) ARGS
-#else
-#define PROTO(ARGS) ()
-#endif
-#endif
-
-#ifdef BUFSIZ /* stdio.h has been included, ok to use FILE * */
-#define STDIO_PROTO(ARGS) PROTO(ARGS)
-#else
-#define STDIO_PROTO(ARGS) ()
-#endif
+#define XPROTO(ARGS) ()
+#define STDIO_XPROTO(ARGS) ()
#ifndef TREE_CODE
union tree_node;
#define Rtx rtx
#endif
-extern void sbss_section PROTO((void));
-extern void sdata_section PROTO((void));
-extern void m32r_init PROTO((void));
-extern int m32r_valid_machine_decl_attribute PROTO((Tree, Tree, Tree, Tree));
-extern int m32r_comp_type_attributes PROTO((Tree, Tree));
-extern void m32r_select_section PROTO((Tree, int));
-extern void m32r_encode_section_info PROTO((Tree));
-extern void m32r_init_expanders PROTO((void));
-extern int call_address_operand PROTO((Rtx, int));
-extern int call_operand PROTO((Rtx, int));
-extern int symbolic_operand PROTO((Rtx, int));
-extern int small_data_operand PROTO((Rtx, int));
-extern int addr24_operand PROTO((Rtx, int));
-extern int addr32_operand PROTO((Rtx, int));
-extern int call26_operand PROTO((Rtx, int));
-extern int seth_add3_operand PROTO((Rtx, int));
-extern int cmp_int16_operand PROTO((Rtx, int));
-extern int uint16_operand PROTO((Rtx, int));
-extern int reg_or_int16_operand PROTO((Rtx, int));
-extern int reg_or_uint16_operand PROTO((Rtx, int));
-extern int reg_or_cmp_nt16_operand PROTO((Rtx, int));
-extern int two_insn_const_operand PROTO((Rtx, int));
-extern int move_src_operand PROTO((Rtx, int));
-extern int move_double_src_operand PROTO((Rtx, int));
-extern int move_dest_operand PROTO((Rtx, int));
-extern int easy_di_const PROTO((Rtx));
-extern int easy_df_const PROTO((Rtx));
-extern int eqne_comparison_operator PROTO((Rtx, int));
-extern int signed_comparison_operator PROTO((Rtx, int));
-extern int memreg_operand PROTO((Rtx, int));
-extern int small_insn_p PROTO((Rtx, int));
-extern int large_insn_p PROTO((Rtx, int));
-extern int m32r_select_cc_mode PROTO((int, Rtx, Rtx));
-extern Rtx gen_compare PROTO((int, Rtx, Rtx, int));
-extern Rtx gen_split_move_double PROTO((Rtx *));
-extern int function_arg_partial_nregs PROTO((CUMULATIVE_ARGS *,
+extern void sbss_section XPROTO((void));
+extern void sdata_section XPROTO((void));
+extern void m32r_init XPROTO((void));
+extern int m32r_valid_machine_decl_attribute XPROTO((Tree, Tree, Tree, Tree));
+extern int m32r_comp_type_attributes XPROTO((Tree, Tree));
+extern void m32r_select_section XPROTO((Tree, int));
+extern void m32r_encode_section_info XPROTO((Tree));
+extern void m32r_init_expanders XPROTO((void));
+extern int call_address_operand XPROTO((Rtx, enum machine_mode));
+extern int call_operand XPROTO((Rtx, enum machine_mode));
+extern int symbolic_operand XPROTO((Rtx, enum machine_mode));
+extern int small_data_operand XPROTO((Rtx, enum machine_mode));
+extern int addr24_operand XPROTO((Rtx, enum machine_mode));
+extern int addr32_operand XPROTO((Rtx, enum machine_mode));
+extern int call26_operand XPROTO((Rtx, enum machine_mode));
+extern int seth_add3_operand XPROTO((Rtx, enum machine_mode));
+extern int cmp_int16_operand XPROTO((Rtx, enum machine_mode));
+extern int uint16_operand XPROTO((Rtx, enum machine_mode));
+extern int reg_or_int16_operand XPROTO((Rtx, enum machine_mode));
+extern int reg_or_uint16_operand XPROTO((Rtx, enum machine_mode));
+extern int reg_or_cmp_nt16_operand XPROTO((Rtx, enum machine_mode));
+extern int two_insn_const_operand XPROTO((Rtx, enum machine_mode));
+extern int move_src_operand XPROTO((Rtx, enum machine_mode));
+extern int move_double_src_operand XPROTO((Rtx, enum machine_mode));
+extern int move_dest_operand XPROTO((Rtx, enum machine_mode));
+extern int easy_di_const XPROTO((Rtx));
+extern int easy_df_const XPROTO((Rtx));
+extern int eqne_comparison_operator XPROTO((Rtx, enum machine_mode));
+extern int signed_comparison_operator XPROTO((Rtx, enum machine_mode));
+extern int memreg_operand XPROTO((Rtx, enum machine_mode));
+extern int small_insn_p XPROTO((Rtx, enum machine_mode));
+extern int large_insn_p XPROTO((Rtx, enum machine_mode));
+extern int m32r_select_cc_mode XPROTO((int, Rtx, Rtx));
+extern Rtx gen_compare XPROTO((int, Rtx, Rtx, int));
+extern Rtx gen_split_move_double XPROTO((Rtx *));
+extern int function_arg_partial_nregs XPROTO((CUMULATIVE_ARGS *,
int, Tree, int));
-extern void m32r_setup_incoming_varargs PROTO((CUMULATIVE_ARGS *,
+extern void m32r_setup_incoming_varargs XPROTO((CUMULATIVE_ARGS *,
int, Tree, int *,
int));
-extern struct rtx_def *m32r_va_arg PROTO((Tree, Tree));
-extern int m32r_address_code PROTO((Rtx));
+extern struct rtx_def *m32r_va_arg XPROTO((Tree, Tree));
+extern int m32r_address_code XPROTO((Rtx));
extern enum m32r_function_type m32r_compute_function_type
- PROTO((Tree));
-extern unsigned m32r_compute_frame_size PROTO((int));
-extern int m32r_first_insn_address PROTO((void));
-extern void m32r_expand_prologue PROTO((void));
-extern void m32r_output_function_prologue STDIO_PROTO((FILE *, int));
-extern void m32r_output_function_epilogue STDIO_PROTO((FILE *, int));
-extern void m32r_finalize_pic PROTO((void));
-extern void m32r_initialize_trampoline PROTO((Rtx, Rtx, Rtx));
-extern void m32r_asm_file_start STDIO_PROTO((FILE *));
-extern void m32r_print_operand STDIO_PROTO((FILE *, Rtx, int));
-extern void m32r_print_operand_address STDIO_PROTO((FILE *, Rtx));
-extern int zero_and_one PROTO((Rtx, Rtx));
-extern int conditional_move_operand PROTO((Rtx, int));
-extern int carry_compare_operand PROTO((Rtx, int));
-extern char *emit_cond_move PROTO((Rtx *, Rtx));
-
-extern char * m32r_output_block_move PROTO((Rtx, Rtx *));
-extern int m32r_block_immediate_operand PROTO((Rtx, int));
-extern void m32r_expand_block_move PROTO((Rtx *));
+ XPROTO((Tree));
+extern unsigned m32r_compute_frame_size XPROTO((int));
+extern int m32r_first_insn_address XPROTO((void));
+extern void m32r_expand_prologue XPROTO((void));
+extern void m32r_output_function_prologue STDIO_XPROTO((FILE *, int));
+extern void m32r_output_function_epilogue STDIO_XPROTO((FILE *, int));
+extern void m32r_finalize_pic XPROTO((void));
+extern void m32r_initialize_trampoline XPROTO((Rtx, Rtx, Rtx));
+extern void m32r_asm_file_start STDIO_XPROTO((FILE *));
+extern void m32r_print_operand STDIO_XPROTO((FILE *, Rtx, int));
+extern void m32r_print_operand_address STDIO_XPROTO((FILE *, Rtx));
+extern int zero_and_one XPROTO((Rtx, Rtx));
+extern int conditional_move_operand XPROTO((Rtx, enum machine_mode));
+extern int carry_compare_operand XPROTO((Rtx, enum machine_mode));
+extern char *emit_cond_move XPROTO((Rtx *, Rtx));
+
+extern char * m32r_output_block_move XPROTO((Rtx, Rtx *));
+extern int m32r_block_immediate_operand XPROTO((Rtx, enum machine_mode));
+extern void m32r_expand_block_move XPROTO((Rtx *));
+
+#undef XPROTO
+#undef STDIO_XPROTO