summaryrefslogtreecommitdiff
path: root/gcc/config/iq2000
diff options
context:
space:
mode:
authorNathan Froyd <froydnj@codesourcery.com>2010-06-17 18:13:03 +0000
committerNathan Froyd <froydnj@gcc.gnu.org>2010-06-17 18:13:03 +0000
commitbf7c1408ffa0f6baa86fa09815b0daf287b74cb9 (patch)
tree8d389f9eb157d90f5f0dc6aa212cd8b58a3172aa /gcc/config/iq2000
parent0fb30cb73d96d9ed538bf3ded15e949e59eaf90e (diff)
downloadgcc-bf7c1408ffa0f6baa86fa09815b0daf287b74cb9.tar.gz
iq2000-protos.h (print_operand): Delete.
* config/iq2000/iq2000-protos.h (print_operand): Delete. (print_operand_address): Delete. * config/iq2000/iq2000.h (PRINT_OPERAND): Delete. (PRINT_OPERAND_PUNCT_VALID_P): Delete. (PRINT_OPERAND_ADDRESS): Delete. (iq2000_print_operand_punct): Delete. * config/iq2000/iq2000.c (iq2000_print_operand_punct): Make static. (iq2000_print_operand_address): Make static. (iq2000_print_operand): Make static. (iq2000_print_operand_punct_valid_p): New function. (TARGET_PRINT_OPERAND, TARGET_PRINT_OPERAND_ADDRESS): (TARGET_PRINT_OPERAND_ADDRESS): Define. From-SVN: r160938
Diffstat (limited to 'gcc/config/iq2000')
-rw-r--r--gcc/config/iq2000/iq2000-protos.h2
-rw-r--r--gcc/config/iq2000/iq2000.c33
-rw-r--r--gcc/config/iq2000/iq2000.h10
3 files changed, 24 insertions, 21 deletions
diff --git a/gcc/config/iq2000/iq2000-protos.h b/gcc/config/iq2000/iq2000-protos.h
index c01b6eee3b9..56fd39e7bc6 100644
--- a/gcc/config/iq2000/iq2000-protos.h
+++ b/gcc/config/iq2000/iq2000-protos.h
@@ -35,8 +35,6 @@ extern void iq2000_expand_eh_return (rtx);
extern int iq2000_can_use_return_insn (void);
extern int iq2000_adjust_insn_length (rtx, int);
extern char * iq2000_output_conditional_branch (rtx, rtx *, int, int, int, int);
-extern void print_operand_address (FILE *, rtx);
-extern void print_operand (FILE *, rtx, int);
#ifdef RTX_CODE
extern rtx gen_int_relational (enum rtx_code, rtx, rtx, rtx, int *);
diff --git a/gcc/config/iq2000/iq2000.c b/gcc/config/iq2000/iq2000.c
index fc8c4e56789..559d88433fa 100644
--- a/gcc/config/iq2000/iq2000.c
+++ b/gcc/config/iq2000/iq2000.c
@@ -108,8 +108,8 @@ struct GTY(()) machine_function
/* Global variables for machine-dependent things. */
-/* List of all IQ2000 punctuation characters used by print_operand. */
-char iq2000_print_operand_punct[256];
+/* List of all IQ2000 punctuation characters used by iq2000_print_operand. */
+static char iq2000_print_operand_punct[256];
/* The target cpu for optimization and scheduling. */
enum processor_type iq2000_tune;
@@ -169,6 +169,9 @@ static void iq2000_asm_trampoline_template (FILE *);
static void iq2000_trampoline_init (rtx, tree, rtx);
static rtx iq2000_function_value (const_tree, const_tree, bool);
static rtx iq2000_libcall_value (enum machine_mode, const_rtx);
+static void iq2000_print_operand (FILE *, rtx, int);
+static void iq2000_print_operand_address (FILE *, rtx);
+static bool iq2000_print_operand_punct_valid_p (unsigned char code);
#undef TARGET_INIT_BUILTINS
#define TARGET_INIT_BUILTINS iq2000_init_builtins
@@ -193,6 +196,13 @@ static rtx iq2000_libcall_value (enum machine_mode, const_rtx);
#undef TARGET_HAVE_SWITCHABLE_BSS_SECTIONS
#define TARGET_HAVE_SWITCHABLE_BSS_SECTIONS false
+#undef TARGET_PRINT_OPERAND
+#define TARGET_PRINT_OPERAND iq2000_print_operand
+#undef TARGET_PRINT_OPERAND_ADDRESS
+#define TARGET_PRINT_OPERAND_ADDRESS iq2000_print_operand_address
+#undef TARGET_PRINT_OPERAND_PUNCT_VALID_P
+#define TARGET_PRINT_OPERAND_PUNCT_VALID_P iq2000_print_operand_punct_valid_p
+
#undef TARGET_PROMOTE_FUNCTION_MODE
#define TARGET_PROMOTE_FUNCTION_MODE default_promote_function_mode_always_promote
#undef TARGET_PROMOTE_PROTOTYPES
@@ -2920,8 +2930,8 @@ iq2000_setup_incoming_varargs (CUMULATIVE_ARGS *cum,
assembler syntax for an instruction operand that is a memory
reference whose address is ADDR. ADDR is an RTL expression. */
-void
-print_operand_address (FILE * file, rtx addr)
+static void
+iq2000_print_operand_address (FILE * file, rtx addr)
{
if (!addr)
error ("PRINT_OPERAND_ADDRESS, null pointer");
@@ -2946,7 +2956,7 @@ print_operand_address (FILE * file, rtx addr)
"PRINT_OPERAND_ADDRESS, LO_SUM with #1 not REG.");
fprintf (file, "%%lo(");
- print_operand_address (file, arg1);
+ iq2000_print_operand_address (file, arg1);
fprintf (file, ")(%s)", reg_names [REGNO (arg0)]);
}
break;
@@ -3048,12 +3058,12 @@ print_operand_address (FILE * file, rtx addr)
'$' Print the name of the stack pointer register (sp or $29).
'+' Print the name of the gp register (gp or $28). */
-void
-print_operand (FILE *file, rtx op, int letter)
+static void
+iq2000_print_operand (FILE *file, rtx op, int letter)
{
enum rtx_code code;
- if (PRINT_OPERAND_PUNCT_VALID_P (letter))
+ if (iq2000_print_operand_punct_valid_p (letter))
{
switch (letter)
{
@@ -3234,13 +3244,18 @@ print_operand (FILE *file, rtx op, int letter)
else if (code == CONST && GET_CODE (XEXP (op, 0)) == REG)
{
- print_operand (file, XEXP (op, 0), letter);
+ iq2000_print_operand (file, XEXP (op, 0), letter);
}
else
output_addr_const (file, op);
}
+static bool
+iq2000_print_operand_punct_valid_p (unsigned char code)
+{
+ return iq2000_print_operand_punct[code];
+}
/* For the IQ2000, transform:
diff --git a/gcc/config/iq2000/iq2000.h b/gcc/config/iq2000/iq2000.h
index fe97f206f96..53a6b5cad04 100644
--- a/gcc/config/iq2000/iq2000.h
+++ b/gcc/config/iq2000/iq2000.h
@@ -571,13 +571,6 @@ typedef struct iq2000_args
#define FINAL_PRESCAN_INSN(INSN, OPVEC, NOPERANDS) \
final_prescan_insn (INSN, OPVEC, NOPERANDS)
-/* See iq2000.c for the IQ2000 specific codes. */
-#define PRINT_OPERAND(FILE, X, CODE) print_operand (FILE, X, CODE)
-
-#define PRINT_OPERAND_PUNCT_VALID_P(CODE) iq2000_print_operand_punct[CODE]
-
-#define PRINT_OPERAND_ADDRESS(FILE, ADDR) print_operand_address (FILE, ADDR)
-
#define DBR_OUTPUT_SEQEND(STREAM) \
do \
{ \
@@ -920,9 +913,6 @@ enum processor_type
#define SDATA_SECTION_ASM_OP "\t.sdata" /* Small data. */
-/* List of all IQ2000 punctuation characters used by print_operand. */
-extern char iq2000_print_operand_punct[256];
-
/* The target cpu for optimization and scheduling. */
extern enum processor_type iq2000_tune;