summaryrefslogtreecommitdiff
path: root/gcc/config/pdp11
diff options
context:
space:
mode:
authorsteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2003-09-28 12:09:07 +0000
committersteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2003-09-28 12:09:07 +0000
commit4b7e50ec1ab20884f98f90674419472a7af982d1 (patch)
tree2d79b08b990c3fd3b3ff14ea4511d3a1600a488b /gcc/config/pdp11
parent4356b80a29e877c9d67386c5bc5ef86228377b33 (diff)
downloadgcc-4b7e50ec1ab20884f98f90674419472a7af982d1.tar.gz
* config/pdp11/pdp11-protos.h, config/pdp11/pdp11.c,
config/c4x/c4x-c.c, config/c4x/c4x-protos.h, config/c4x/c4x.c, config/c4x/c4x.h: Convert to ISO C90 function declarations and definitions. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@71880 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/pdp11')
-rw-r--r--gcc/config/pdp11/pdp11-protos.h36
-rw-r--r--gcc/config/pdp11/pdp11.c106
2 files changed, 49 insertions, 93 deletions
diff --git a/gcc/config/pdp11/pdp11-protos.h b/gcc/config/pdp11/pdp11-protos.h
index a0e77222fb4..2aebab01dc5 100644
--- a/gcc/config/pdp11/pdp11-protos.h
+++ b/gcc/config/pdp11/pdp11-protos.h
@@ -1,5 +1,5 @@
/* Definitions of target machine for GNU compiler, for the pdp-11
- Copyright (C) 2000 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2003 Free Software Foundation, Inc.
Contributed by Michael K. Gschwind (mike@vlsivie.tuwien.ac.at).
This file is part of GCC.
@@ -21,23 +21,23 @@ Boston, MA 02111-1307, USA. */
/* declarations */
#ifdef RTX_CODE
-extern int arith_operand PARAMS ((rtx, enum machine_mode));
-extern int const_immediate_operand PARAMS ((rtx, enum machine_mode));
-extern int expand_shift_operand PARAMS ((rtx, enum machine_mode));
-extern int immediate15_operand PARAMS ((rtx, enum machine_mode));
-extern int simple_memory_operand PARAMS ((rtx, enum machine_mode));
-extern int comp_operator PARAMS ((rtx, enum machine_mode));
+extern int arith_operand (rtx, enum machine_mode);
+extern int const_immediate_operand (rtx, enum machine_mode);
+extern int expand_shift_operand (rtx, enum machine_mode);
+extern int immediate15_operand (rtx, enum machine_mode);
+extern int simple_memory_operand (rtx, enum machine_mode);
+extern int comp_operator (rtx, enum machine_mode);
-extern int legitimate_address_p PARAMS ((enum machine_mode, rtx));
-extern void notice_update_cc_on_set PARAMS ((rtx, rtx));
-extern void output_addr_const_pdp11 PARAMS ((FILE *, rtx));
-extern const char *output_move_double PARAMS ((rtx *));
-extern const char *output_move_quad PARAMS ((rtx *));
-extern const char *output_block_move PARAMS ((rtx *));
-extern void print_operand_address PARAMS ((FILE *, rtx));
-extern int register_move_cost PARAMS ((enum reg_class, enum reg_class));
-extern int comparison_operator_index PARAMS ((rtx));
+extern int legitimate_address_p (enum machine_mode, rtx);
+extern void notice_update_cc_on_set (rtx, rtx);
+extern void output_addr_const_pdp11 (FILE *, rtx);
+extern const char *output_move_double (rtx *);
+extern const char *output_move_quad (rtx *);
+extern const char *output_block_move (rtx *);
+extern void print_operand_address (FILE *, rtx);
+extern int register_move_cost (enum reg_class, enum reg_class);
+extern int comparison_operator_index (rtx);
#endif /* RTX_CODE */
-extern void output_ascii PARAMS ((FILE *, const char *, int));
-extern const char *output_jump PARAMS ((const char *, const char *, int));
+extern void output_ascii (FILE *, const char *, int);
+extern const char *output_jump (const char *, const char *, int);
diff --git a/gcc/config/pdp11/pdp11.c b/gcc/config/pdp11/pdp11.c
index dbb1859d3db..02565432cda 100644
--- a/gcc/config/pdp11/pdp11.c
+++ b/gcc/config/pdp11/pdp11.c
@@ -54,12 +54,12 @@ int current_first_parm_offset;
/* This is where the condition code register lives. */
/* rtx cc0_reg_rtx; - no longer needed? */
-static rtx find_addr_reg PARAMS ((rtx));
-static const char *singlemove_string PARAMS ((rtx *));
-static bool pdp11_assemble_integer PARAMS ((rtx, unsigned int, int));
-static void pdp11_output_function_prologue PARAMS ((FILE *, HOST_WIDE_INT));
-static void pdp11_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
-static bool pdp11_rtx_costs PARAMS ((rtx, int, int, int *));
+static rtx find_addr_reg (rtx);
+static const char *singlemove_string (rtx *);
+static bool pdp11_assemble_integer (rtx, unsigned int, int);
+static void pdp11_output_function_prologue (FILE *, HOST_WIDE_INT);
+static void pdp11_output_function_epilogue (FILE *, HOST_WIDE_INT);
+static bool pdp11_rtx_costs (rtx, int, int, int *);
/* Initialize the GCC target structure. */
#undef TARGET_ASM_BYTE_OP
@@ -89,33 +89,25 @@ struct gcc_target targetm = TARGET_INITIALIZER;
/* Nonzero if OP is a valid second operand for an arithmetic insn. */
int
-arith_operand (op, mode)
- rtx op;
- enum machine_mode mode;
+arith_operand (rtx op, enum machine_mode mode)
{
return (register_operand (op, mode) || GET_CODE (op) == CONST_INT);
}
int
-const_immediate_operand (op, mode)
- rtx op;
- enum machine_mode mode ATTRIBUTE_UNUSED;
+const_immediate_operand (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
{
return (GET_CODE (op) == CONST_INT);
}
int
-immediate15_operand (op, mode)
- rtx op;
- enum machine_mode mode ATTRIBUTE_UNUSED;
+immediate15_operand (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
{
return (GET_CODE (op) == CONST_INT && ((INTVAL (op) & 0x8000) == 0x0000));
}
int
-expand_shift_operand (op, mode)
- rtx op;
- enum machine_mode mode ATTRIBUTE_UNUSED;
+expand_shift_operand (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
{
return (GET_CODE (op) == CONST_INT
&& abs (INTVAL(op)) > 1
@@ -134,9 +126,7 @@ expand_shift_operand (op, mode)
#ifdef TWO_BSD
static void
-pdp11_output_function_prologue (stream, size)
- FILE *stream;
- HOST_WIDE_INT size;
+pdp11_output_function_prologue (FILE *stream, HOST_WIDE_INT size)
{
fprintf (stream, "\tjsr r5, csv\n");
if (size)
@@ -151,9 +141,7 @@ pdp11_output_function_prologue (stream, size)
#else /* !TWO_BSD */
static void
-pdp11_output_function_prologue (stream, size)
- FILE *stream;
- HOST_WIDE_INT size;
+pdp11_output_function_prologue (FILE *stream, HOST_WIDE_INT size)
{
HOST_WIDE_INT fsize = ((size) + 1) & ~1;
int regno;
@@ -249,9 +237,8 @@ pdp11_output_function_prologue (stream, size)
#ifdef TWO_BSD
static void
-pdp11_output_function_epilogue (stream, size)
- FILE *stream;
- HOST_WIDE_INT size ATTRIBUTE_UNUSED;
+pdp11_output_function_epilogue (FILE *stream,
+ HOST_WIDE_INT size ATTRIBUTE_UNUSED)
{
fprintf (stream, "\t/* SP ignored by cret? */\n");
fprintf (stream, "\tjmp cret\n");
@@ -260,9 +247,7 @@ pdp11_output_function_epilogue (stream, size)
#else /* !TWO_BSD */
static void
-pdp11_output_function_epilogue (stream, size)
- FILE *stream;
- HOST_WIDE_INT size;
+pdp11_output_function_epilogue (FILE *stream, HOST_WIDE_INT size)
{
HOST_WIDE_INT fsize = ((size) + 1) & ~1;
int i, j, k;
@@ -369,8 +354,7 @@ pdp11_output_function_epilogue (stream, size)
/* Return the best assembler insn template
for moving operands[1] into operands[0] as a fullword. */
static const char *
-singlemove_string (operands)
- rtx *operands;
+singlemove_string (rtx *operands)
{
if (operands[1] != const0_rtx)
return "mov %1,%0";
@@ -383,8 +367,7 @@ singlemove_string (operands)
with operands OPERANDS. */
const char *
-output_move_double (operands)
- rtx *operands;
+output_move_double (rtx *operands)
{
enum { REGOP, OFFSOP, MEMOP, PUSHOP, POPOP, CNSTOP, RNDOP } optype0, optype1;
rtx latehalf[2];
@@ -562,8 +545,7 @@ output_move_double (operands)
with operands OPERANDS. */
const char *
-output_move_quad (operands)
- rtx *operands;
+output_move_quad (rtx *operands)
{
enum { REGOP, OFFSOP, MEMOP, PUSHOP, POPOP, CNSTOP, RNDOP } optype0, optype1;
rtx latehalf[2];
@@ -787,8 +769,7 @@ output_move_quad (operands)
ADDR can be effectively incremented by incrementing REG. */
static rtx
-find_addr_reg (addr)
- rtx addr;
+find_addr_reg (rtx addr)
{
while (GET_CODE (addr) == PLUS)
{
@@ -808,10 +789,7 @@ find_addr_reg (addr)
/* Output an ascii string. */
void
-output_ascii (file, p, size)
- FILE *file;
- const char *p;
- int size;
+output_ascii (FILE *file, const char *p, int size)
{
int i;
@@ -835,9 +813,7 @@ output_ascii (file, p, size)
/* --- stole from out-vax, needs changes */
void
-print_operand_address (file, addr)
- FILE *file;
- register rtx addr;
+print_operand_address (FILE *file, register rtx addr)
{
register rtx reg1, reg2, breg, ireg;
rtx offset;
@@ -967,10 +943,7 @@ print_operand_address (file, addr)
pdp-specific version of output_addr_const. */
static bool
-pdp11_assemble_integer (x, size, aligned_p)
- rtx x;
- unsigned int size;
- int aligned_p;
+pdp11_assemble_integer (rtx x, unsigned int size, int aligned_p)
{
if (aligned_p)
switch (size)
@@ -1020,10 +993,7 @@ register_move_cost(c1, c2)
}
static bool
-pdp11_rtx_costs (x, code, outer_code, total)
- rtx x;
- int code, outer_code ATTRIBUTE_UNUSED;
- int *total;
+pdp11_rtx_costs (rtx x, int code, int outer_code ATTRIBUTE_UNUSED, int *total)
{
switch (code)
{
@@ -1130,9 +1100,7 @@ pdp11_rtx_costs (x, code, outer_code, total)
}
const char *
-output_jump(pos, neg, length)
- const char *pos, *neg;
- int length;
+output_jump(const char *pos, const char *neg, int length)
{
static int x = 0;
@@ -1173,9 +1141,7 @@ output_jump(pos, neg, length)
}
void
-notice_update_cc_on_set(exp, insn)
- rtx exp;
- rtx insn ATTRIBUTE_UNUSED;
+notice_update_cc_on_set(rtx exp, rtx insn ATTRIBUTE_UNUSED)
{
if (GET_CODE (SET_DEST (exp)) == CC0)
{
@@ -1245,9 +1211,7 @@ notice_update_cc_on_set(exp, insn)
int
-simple_memory_operand(op, mode)
- rtx op;
- enum machine_mode mode ATTRIBUTE_UNUSED;
+simple_memory_operand(rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
{
rtx addr;
@@ -1320,8 +1284,7 @@ simple_memory_operand(op, mode)
const char *
-output_block_move(operands)
- rtx *operands;
+output_block_move(rtx *operands)
{
static int count = 0;
char buf[200];
@@ -1560,8 +1523,7 @@ output_block_move(operands)
/* for future use */
int
-comparison_operator_index(op)
- rtx op;
+comparison_operator_index(rtx op)
{
switch (GET_CODE(op))
{
@@ -1602,18 +1564,14 @@ comparison_operator_index(op)
/* tests whether the rtx is a comparison operator */
int
-comp_operator (op, mode)
- rtx op;
- enum machine_mode mode ATTRIBUTE_UNUSED;
+comp_operator (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
{
return comparison_operator_index(op) >= 0;
}
int
-legitimate_address_p (mode, address)
- enum machine_mode mode;
- rtx address;
+legitimate_address_p (enum machine_mode mode, rtx address)
{
/* #define REG_OK_STRICT */
GO_IF_LEGITIMATE_ADDRESS(mode, address, win);
@@ -1632,9 +1590,7 @@ legitimate_address_p (mode, address)
So this copy should get called whenever needed.
*/
void
-output_addr_const_pdp11 (file, x)
- FILE *file;
- rtx x;
+output_addr_const_pdp11 (FILE *file, rtx x)
{
char buf[256];