Commit 761c70aa by Kaveh R. Ghazi Committed by Kaveh Ghazi

arc.c (output_shift): Use stdio instead of asm_fprintf.

	* arc.c (output_shift): Use stdio instead of asm_fprintf.
	* arm.c (thumb_output_function_prologue): Likewise.
	* avr.c (print_operand): Likewise.
	* c4x.c (c4x_print_operand): Likewise.
	* c4x.h (ASM_OUTPUT_INTERNAL_LABEL, TRAMPOLINE_TEMPLATE,
	ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Likewise.
	* cris.c (cris_target_asm_function_prologue,
	cris_asm_output_mi_thunk): Likewise.
	* h8300.c (print_operand): Likewise.
	* h8300.h (ASM_OUTPUT_ADDR_VEC_ELT): Likewise.
	* ip2k.c (print_operand): Likewise.  Fix format specifier.
	* m68hc11.c (asm_print_register, print_operand,
	print_operand_address): Use stdio instead of asm_fprintf.
	(print_operand_address): Fix format specifier.
	* m68hc11.h (FUNCTION_PROFILER, ASM_OUTPUT_ADDR_DIFF_ELT,
	ASM_OUTPUT_ADDR_VEC_ELT, ASM_OUTPUT_ALIGN): Use stdio instead of
	asm_fprintf.
	* m68k/amix.h (ASM_OUTPUT_INTERNAL_LABEL): Likewise.
	* m68k/atari.h (ASM_OUTPUT_INTERNAL_LABEL): Likewise.
	* m68k.c (m68k_output_function_prologue,
	m68k_output_function_epilogue, print_operand): Likewise.
	* mmix.c (mmix_asm_output_mi_thunk, mmix_asm_weaken_label):
	Likewise.  Fix format specifier.
	* mn10200.h (ASM_OUTPUT_ADDR_VEC_ELT): Likewise.
	* mn10300.h (ASM_OUTPUT_ADDR_VEC_ELT): Likewise.
	* v850.h (ASM_OUTPUT_ADDR_VEC_ELT): Likewise.

From-SVN: r56472
parent 5ce6f47b
2002-08-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* arc.c (output_shift): Use stdio instead of asm_fprintf.
* arm.c (thumb_output_function_prologue): Likewise.
* avr.c (print_operand): Likewise.
* c4x.c (c4x_print_operand): Likewise.
* c4x.h (ASM_OUTPUT_INTERNAL_LABEL, TRAMPOLINE_TEMPLATE,
ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Likewise.
* cris.c (cris_target_asm_function_prologue,
cris_asm_output_mi_thunk): Likewise.
* h8300.c (print_operand): Likewise.
* h8300.h (ASM_OUTPUT_ADDR_VEC_ELT): Likewise.
* ip2k.c (print_operand): Likewise. Fix format specifier.
* m68hc11.c (asm_print_register, print_operand,
print_operand_address): Use stdio instead of asm_fprintf.
(print_operand_address): Fix format specifier.
* m68hc11.h (FUNCTION_PROFILER, ASM_OUTPUT_ADDR_DIFF_ELT,
ASM_OUTPUT_ADDR_VEC_ELT, ASM_OUTPUT_ALIGN): Use stdio instead of
asm_fprintf.
* m68k/amix.h (ASM_OUTPUT_INTERNAL_LABEL): Likewise.
* m68k/atari.h (ASM_OUTPUT_INTERNAL_LABEL): Likewise.
* m68k.c (m68k_output_function_prologue,
m68k_output_function_epilogue, print_operand): Likewise.
* mmix.c (mmix_asm_output_mi_thunk, mmix_asm_weaken_label):
Likewise. Fix format specifier.
* mn10200.h (ASM_OUTPUT_ADDR_VEC_ELT): Likewise.
* mn10300.h (ASM_OUTPUT_ADDR_VEC_ELT): Likewise.
* v850.h (ASM_OUTPUT_ADDR_VEC_ELT): Likewise.
2002-08-15 Eric Christopher <echristo@redhat.com> 2002-08-15 Eric Christopher <echristo@redhat.com>
Jeff Knaggs <jknaggs@redhat.com> Jeff Knaggs <jknaggs@redhat.com>
......
...@@ -1553,23 +1553,23 @@ output_shift (operands) ...@@ -1553,23 +1553,23 @@ output_shift (operands)
output_asm_insn ("sr %4,[lp_end]", operands); output_asm_insn ("sr %4,[lp_end]", operands);
output_asm_insn ("nop\n\tnop", operands); output_asm_insn ("nop\n\tnop", operands);
if (flag_pic) if (flag_pic)
asm_fprintf (asm_out_file, "\t%s single insn loop\n", fprintf (asm_out_file, "\t%s single insn loop\n",
ASM_COMMENT_START); ASM_COMMENT_START);
else else
asm_fprintf (asm_out_file, "1:\t%s single insn loop\n", fprintf (asm_out_file, "1:\t%s single insn loop\n",
ASM_COMMENT_START); ASM_COMMENT_START);
output_asm_insn (shift_one, operands); output_asm_insn (shift_one, operands);
} }
else else
{ {
asm_fprintf (asm_out_file, "1:\t%s begin shift loop\n", fprintf (asm_out_file, "1:\t%s begin shift loop\n",
ASM_COMMENT_START); ASM_COMMENT_START);
output_asm_insn ("sub.f %4,%4,1", operands); output_asm_insn ("sub.f %4,%4,1", operands);
output_asm_insn ("nop", operands); output_asm_insn ("nop", operands);
output_asm_insn ("bn.nd 2f", operands); output_asm_insn ("bn.nd 2f", operands);
output_asm_insn (shift_one, operands); output_asm_insn (shift_one, operands);
output_asm_insn ("b.nd 1b", operands); output_asm_insn ("b.nd 1b", operands);
asm_fprintf (asm_out_file, "2:\t%s end shift loop\n", fprintf (asm_out_file, "2:\t%s end shift loop\n",
ASM_COMMENT_START); ASM_COMMENT_START);
} }
} }
......
...@@ -10283,13 +10283,13 @@ thumb_output_function_prologue (f, size) ...@@ -10283,13 +10283,13 @@ thumb_output_function_prologue (f, size)
#define STUB_NAME ".real_start_of" #define STUB_NAME ".real_start_of"
asm_fprintf (f, "\t.code\t16\n"); fprintf (f, "\t.code\t16\n");
#ifdef ARM_PE #ifdef ARM_PE
if (arm_dllexport_name_p (name)) if (arm_dllexport_name_p (name))
name = arm_strip_name_encoding (name); name = arm_strip_name_encoding (name);
#endif #endif
asm_fprintf (f, "\t.globl %s%U%s\n", STUB_NAME, name); asm_fprintf (f, "\t.globl %s%U%s\n", STUB_NAME, name);
asm_fprintf (f, "\t.thumb_func\n"); fprintf (f, "\t.thumb_func\n");
asm_fprintf (f, "%s%U%s:\n", STUB_NAME, name); asm_fprintf (f, "%s%U%s:\n", STUB_NAME, name);
} }
...@@ -10299,7 +10299,7 @@ thumb_output_function_prologue (f, size) ...@@ -10299,7 +10299,7 @@ thumb_output_function_prologue (f, size)
{ {
int num_pushes; int num_pushes;
asm_fprintf (f, "\tpush\t{"); fprintf (f, "\tpush\t{");
num_pushes = ARM_NUM_INTS (current_function_pretend_args_size); num_pushes = ARM_NUM_INTS (current_function_pretend_args_size);
...@@ -10309,7 +10309,7 @@ thumb_output_function_prologue (f, size) ...@@ -10309,7 +10309,7 @@ thumb_output_function_prologue (f, size)
asm_fprintf (f, "%r%s", regno, asm_fprintf (f, "%r%s", regno,
regno == LAST_ARG_REGNUM ? "" : ", "); regno == LAST_ARG_REGNUM ? "" : ", ");
asm_fprintf (f, "}\n"); fprintf (f, "}\n");
} }
else else
asm_fprintf (f, "\tsub\t%r, %r, #%d\n", asm_fprintf (f, "\tsub\t%r, %r, #%d\n",
......
...@@ -1156,12 +1156,12 @@ print_operand (file, x, code) ...@@ -1156,12 +1156,12 @@ print_operand (file, x, code)
fatal_insn ("internal compiler error. Unknown mode:", x); fatal_insn ("internal compiler error. Unknown mode:", x);
REAL_VALUE_FROM_CONST_DOUBLE (rv, x); REAL_VALUE_FROM_CONST_DOUBLE (rv, x);
REAL_VALUE_TO_TARGET_SINGLE (rv, val); REAL_VALUE_TO_TARGET_SINGLE (rv, val);
asm_fprintf (file, "0x%lx", val); fprintf (file, "0x%lx", val);
} }
else if (code == 'j') else if (code == 'j')
asm_fprintf (file, cond_string (GET_CODE (x))); fputs (cond_string (GET_CODE (x)), file);
else if (code == 'k') else if (code == 'k')
asm_fprintf (file, cond_string (reverse_condition (GET_CODE (x)))); fputs (cond_string (reverse_condition (GET_CODE (x))), file);
else else
print_operand_address (file, x); print_operand_address (file, x);
} }
......
...@@ -1850,7 +1850,7 @@ c4x_print_operand (file, op, letter) ...@@ -1850,7 +1850,7 @@ c4x_print_operand (file, op, letter)
{ {
case '#': /* Delayed. */ case '#': /* Delayed. */
if (final_sequence) if (final_sequence)
asm_fprintf (file, "d"); fprintf (file, "d");
return; return;
} }
...@@ -1859,7 +1859,7 @@ c4x_print_operand (file, op, letter) ...@@ -1859,7 +1859,7 @@ c4x_print_operand (file, op, letter)
{ {
case 'A': /* Direct address. */ case 'A': /* Direct address. */
if (code == CONST_INT || code == SYMBOL_REF || code == CONST) if (code == CONST_INT || code == SYMBOL_REF || code == CONST)
asm_fprintf (file, "@"); fprintf (file, "@");
break; break;
case 'H': /* Sethi. */ case 'H': /* Sethi. */
...@@ -1892,9 +1892,9 @@ c4x_print_operand (file, op, letter) ...@@ -1892,9 +1892,9 @@ c4x_print_operand (file, op, letter)
op1 = XEXP (XEXP (op, 0), 1); op1 = XEXP (XEXP (op, 0), 1);
if (GET_CODE(op1) == CONST_INT || GET_CODE(op1) == SYMBOL_REF) if (GET_CODE(op1) == CONST_INT || GET_CODE(op1) == SYMBOL_REF)
{ {
asm_fprintf (file, "\t%s\t@", TARGET_C3X ? "ldp" : "ldpk"); fprintf (file, "\t%s\t@", TARGET_C3X ? "ldp" : "ldpk");
output_address (XEXP (adjust_address (op, VOIDmode, 1), 0)); output_address (XEXP (adjust_address (op, VOIDmode, 1), 0));
asm_fprintf (file, "\n"); fprintf (file, "\n");
} }
} }
return; return;
...@@ -1905,9 +1905,9 @@ c4x_print_operand (file, op, letter) ...@@ -1905,9 +1905,9 @@ c4x_print_operand (file, op, letter)
&& (GET_CODE (XEXP (op, 0)) == CONST && (GET_CODE (XEXP (op, 0)) == CONST
|| GET_CODE (XEXP (op, 0)) == SYMBOL_REF)) || GET_CODE (XEXP (op, 0)) == SYMBOL_REF))
{ {
asm_fprintf (file, "%s\t@", TARGET_C3X ? "ldp" : "ldpk"); fprintf (file, "%s\t@", TARGET_C3X ? "ldp" : "ldpk");
output_address (XEXP (op, 0)); output_address (XEXP (op, 0));
asm_fprintf (file, "\n\t"); fprintf (file, "\n\t");
} }
return; return;
...@@ -1927,7 +1927,7 @@ c4x_print_operand (file, op, letter) ...@@ -1927,7 +1927,7 @@ c4x_print_operand (file, op, letter)
case 'U': /* Call/callu. */ case 'U': /* Call/callu. */
if (code != SYMBOL_REF) if (code != SYMBOL_REF)
asm_fprintf (file, "u"); fprintf (file, "u");
return; return;
default: default:
...@@ -1964,43 +1964,43 @@ c4x_print_operand (file, op, letter) ...@@ -1964,43 +1964,43 @@ c4x_print_operand (file, op, letter)
break; break;
case NE: case NE:
asm_fprintf (file, "ne"); fprintf (file, "ne");
break; break;
case EQ: case EQ:
asm_fprintf (file, "eq"); fprintf (file, "eq");
break; break;
case GE: case GE:
asm_fprintf (file, "ge"); fprintf (file, "ge");
break; break;
case GT: case GT:
asm_fprintf (file, "gt"); fprintf (file, "gt");
break; break;
case LE: case LE:
asm_fprintf (file, "le"); fprintf (file, "le");
break; break;
case LT: case LT:
asm_fprintf (file, "lt"); fprintf (file, "lt");
break; break;
case GEU: case GEU:
asm_fprintf (file, "hs"); fprintf (file, "hs");
break; break;
case GTU: case GTU:
asm_fprintf (file, "hi"); fprintf (file, "hi");
break; break;
case LEU: case LEU:
asm_fprintf (file, "ls"); fprintf (file, "ls");
break; break;
case LTU: case LTU:
asm_fprintf (file, "lo"); fprintf (file, "lo");
break; break;
case SYMBOL_REF: case SYMBOL_REF:
......
...@@ -1733,7 +1733,7 @@ c4x_file_end (FILE) ...@@ -1733,7 +1733,7 @@ c4x_file_end (FILE)
PREFIX is the class of label and NUM is the number within the class. */ PREFIX is the class of label and NUM is the number within the class. */
#define ASM_OUTPUT_INTERNAL_LABEL(FILE, PREFIX, NUM) \ #define ASM_OUTPUT_INTERNAL_LABEL(FILE, PREFIX, NUM) \
asm_fprintf (FILE, "%s%d:\n", PREFIX, NUM) fprintf (FILE, "%s%d:\n", PREFIX, NUM)
/* This is how to store into the string LABEL /* This is how to store into the string LABEL
the symbol_ref name of an internal numbered label where the symbol_ref name of an internal numbered label where
...@@ -1993,27 +1993,27 @@ do { fprintf (asm_out_file, "\t.sdef\t"); \ ...@@ -1993,27 +1993,27 @@ do { fprintf (asm_out_file, "\t.sdef\t"); \
{ \ { \
if (TARGET_C3X) \ if (TARGET_C3X) \
{ \ { \
asm_fprintf (FILE, "\tldiu\t0,ar1\n"); \ fprintf (FILE, "\tldiu\t0,ar1\n"); \
asm_fprintf (FILE, "\tlsh\t16,ar1\n"); \ fprintf (FILE, "\tlsh\t16,ar1\n"); \
asm_fprintf (FILE, "\tor\t0,ar1\n"); \ fprintf (FILE, "\tor\t0,ar1\n"); \
asm_fprintf (FILE, "\tldiu\t0,ar0\n"); \ fprintf (FILE, "\tldiu\t0,ar0\n"); \
asm_fprintf (FILE, "\tbud\tar1\n"); \ fprintf (FILE, "\tbud\tar1\n"); \
asm_fprintf (FILE, "\tlsh\t16,ar0\n"); \ fprintf (FILE, "\tlsh\t16,ar0\n"); \
asm_fprintf (FILE, "\tor\t0,ar0\n"); \ fprintf (FILE, "\tor\t0,ar0\n"); \
asm_fprintf (FILE, "\tor\t1000h,st\n"); \ fprintf (FILE, "\tor\t1000h,st\n"); \
} \ } \
else \ else \
{ \ { \
asm_fprintf (FILE, "\tlaj\t$+4\n"); \ fprintf (FILE, "\tlaj\t$+4\n"); \
asm_fprintf (FILE, "\taddi3\t4,r11,ar0\n"); \ fprintf (FILE, "\taddi3\t4,r11,ar0\n"); \
asm_fprintf (FILE, "\tlda\t*ar0,ar1\n"); \ fprintf (FILE, "\tlda\t*ar0,ar1\n"); \
asm_fprintf (FILE, "\tlda\t*+ar0(1),ar0\n"); \ fprintf (FILE, "\tlda\t*+ar0(1),ar0\n"); \
asm_fprintf (FILE, "\tbud\tar1\n"); \ fprintf (FILE, "\tbud\tar1\n"); \
asm_fprintf (FILE, "\tnop\n"); \ fprintf (FILE, "\tnop\n"); \
asm_fprintf (FILE, "\tnop\n"); \ fprintf (FILE, "\tnop\n"); \
asm_fprintf (FILE, "\tor\t1000h,st\n"); \ fprintf (FILE, "\tor\t1000h,st\n"); \
asm_fprintf (FILE, "\t.word\t0\n"); \ fprintf (FILE, "\t.word\t0\n"); \
asm_fprintf (FILE, "\t.word\t0\n"); \ fprintf (FILE, "\t.word\t0\n"); \
} \ } \
} }
...@@ -2076,13 +2076,13 @@ do { fprintf (asm_out_file, "\t.sdef\t"); \ ...@@ -2076,13 +2076,13 @@ do { fprintf (asm_out_file, "\t.sdef\t"); \
#define BSS_SECTION_ASM_OP "\t.bss" #define BSS_SECTION_ASM_OP "\t.bss"
#define ASM_OUTPUT_REG_PUSH(FILE, REGNO) \ #define ASM_OUTPUT_REG_PUSH(FILE, REGNO) \
asm_fprintf (FILE, "\tpush\t%s\n", reg_names[REGNO]) fprintf (FILE, "\tpush\t%s\n", reg_names[REGNO])
/* This is how to output an insn to pop a register from the stack. /* This is how to output an insn to pop a register from the stack.
It need not be very fast code. */ It need not be very fast code. */
#define ASM_OUTPUT_REG_POP(FILE, REGNO) \ #define ASM_OUTPUT_REG_POP(FILE, REGNO) \
asm_fprintf (FILE, "\tpop\t%s\n", reg_names[REGNO]) fprintf (FILE, "\tpop\t%s\n", reg_names[REGNO])
/* Value is 1 if truncating an integer of INPREC bits to OUTPREC bits /* Value is 1 if truncating an integer of INPREC bits to OUTPREC bits
is done just by pretending it is already truncated. */ is done just by pretending it is already truncated. */
......
...@@ -864,7 +864,7 @@ cris_target_asm_function_prologue (file, size) ...@@ -864,7 +864,7 @@ cris_target_asm_function_prologue (file, size)
/* Set up the PIC register. */ /* Set up the PIC register. */
if (current_function_uses_pic_offset_table) if (current_function_uses_pic_offset_table)
asm_fprintf (file, "\tmove.d $pc,$%s\n\tsub.d .:GOTOFF,$%s\n", fprintf (file, "\tmove.d $pc,$%s\n\tsub.d .:GOTOFF,$%s\n",
reg_names[PIC_OFFSET_TABLE_REGNUM], reg_names[PIC_OFFSET_TABLE_REGNUM],
reg_names[PIC_OFFSET_TABLE_REGNUM]); reg_names[PIC_OFFSET_TABLE_REGNUM]);
...@@ -2580,11 +2580,11 @@ cris_asm_output_mi_thunk (stream, thunkdecl, delta, funcdecl) ...@@ -2580,11 +2580,11 @@ cris_asm_output_mi_thunk (stream, thunkdecl, delta, funcdecl)
tree funcdecl; tree funcdecl;
{ {
if (delta > 0) if (delta > 0)
asm_fprintf (stream, "\tadd%s %d,$%s\n", fprintf (stream, "\tadd%s %d,$%s\n",
ADDITIVE_SIZE_MODIFIER (delta), delta, ADDITIVE_SIZE_MODIFIER (delta), delta,
reg_names[CRIS_FIRST_ARG_REG]); reg_names[CRIS_FIRST_ARG_REG]);
else if (delta < 0) else if (delta < 0)
asm_fprintf (stream, "\tsub%s %d,$%s\n", fprintf (stream, "\tsub%s %d,$%s\n",
ADDITIVE_SIZE_MODIFIER (-delta), -delta, ADDITIVE_SIZE_MODIFIER (-delta), -delta,
reg_names[CRIS_FIRST_ARG_REG]); reg_names[CRIS_FIRST_ARG_REG]);
......
...@@ -1153,10 +1153,10 @@ print_operand (file, x, code) ...@@ -1153,10 +1153,10 @@ print_operand (file, x, code)
} }
break; break;
case 'j': case 'j':
asm_fprintf (file, cond_string (GET_CODE (x))); fputs (cond_string (GET_CODE (x)), file);
break; break;
case 'k': case 'k':
asm_fprintf (file, cond_string (reverse_condition (GET_CODE (x)))); fputs (cond_string (reverse_condition (GET_CODE (x))), file);
break; break;
case 's': case 's':
if (GET_CODE (x) == CONST_INT) if (GET_CODE (x) == CONST_INT)
......
...@@ -1165,7 +1165,7 @@ struct cum_arg ...@@ -1165,7 +1165,7 @@ struct cum_arg
/* This is how to output an element of a case-vector that is absolute. */ /* This is how to output an element of a case-vector that is absolute. */
#define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \ #define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \
asm_fprintf (FILE, "%s.L%d\n", ASM_WORD_OP, VALUE) fprintf (FILE, "%s.L%d\n", ASM_WORD_OP, VALUE)
/* This is how to output an element of a case-vector that is relative. */ /* This is how to output an element of a case-vector that is relative. */
......
...@@ -1060,7 +1060,7 @@ print_operand (file, x, code) ...@@ -1060,7 +1060,7 @@ print_operand (file, x, code)
REAL_VALUE_FROM_CONST_DOUBLE (rv, x); REAL_VALUE_FROM_CONST_DOUBLE (rv, x);
REAL_VALUE_TO_TARGET_SINGLE (rv, value); REAL_VALUE_TO_TARGET_SINGLE (rv, value);
asm_fprintf (file, "0x%x", value); fprintf (file, "0x%lx", value);
} }
break; break;
......
...@@ -2099,7 +2099,7 @@ asm_print_register (file, regno) ...@@ -2099,7 +2099,7 @@ asm_print_register (file, regno)
if (TARGET_NO_DIRECT_MODE && name[0] == '*') if (TARGET_NO_DIRECT_MODE && name[0] == '*')
name++; name++;
asm_fprintf (file, "%s", name); fprintf (file, "%s", name);
} }
/* A C compound statement to output to stdio stream STREAM the /* A C compound statement to output to stdio stream STREAM the
...@@ -2148,7 +2148,7 @@ print_operand (file, op, letter) ...@@ -2148,7 +2148,7 @@ print_operand (file, op, letter)
else if (letter == 'T') else if (letter == 'T')
{ {
asm_print_register (file, SOFT_TMP_REGNUM); asm_print_register (file, SOFT_TMP_REGNUM);
asm_fprintf (file, "+1"); fprintf (file, "+1");
return; return;
} }
else if (letter == '#') else if (letter == '#')
...@@ -2161,7 +2161,7 @@ print_operand (file, op, letter) ...@@ -2161,7 +2161,7 @@ print_operand (file, op, letter)
if (letter == 'b' && S_REG_P (op)) if (letter == 'b' && S_REG_P (op))
{ {
asm_print_register (file, REGNO (op)); asm_print_register (file, REGNO (op));
asm_fprintf (file, "+1"); fprintf (file, "+1");
} }
else else
{ {
...@@ -2178,7 +2178,7 @@ print_operand (file, op, letter) ...@@ -2178,7 +2178,7 @@ print_operand (file, op, letter)
asm_fprintf (file, "%0I%%hi("); asm_fprintf (file, "%0I%%hi(");
output_addr_const (file, op); output_addr_const (file, op);
asm_fprintf (file, ")"); fprintf (file, ")");
return; return;
} }
...@@ -2204,7 +2204,7 @@ print_operand (file, op, letter) ...@@ -2204,7 +2204,7 @@ print_operand (file, op, letter)
case PRE_DEC: case PRE_DEC:
if (TARGET_M6812) if (TARGET_M6812)
{ {
asm_fprintf (file, "%u,-", GET_MODE_SIZE (GET_MODE (op))); fprintf (file, "%u,-", GET_MODE_SIZE (GET_MODE (op)));
asm_print_register (file, REGNO (XEXP (base, 0))); asm_print_register (file, REGNO (XEXP (base, 0)));
} }
else else
...@@ -2214,9 +2214,9 @@ print_operand (file, op, letter) ...@@ -2214,9 +2214,9 @@ print_operand (file, op, letter)
case POST_DEC: case POST_DEC:
if (TARGET_M6812) if (TARGET_M6812)
{ {
asm_fprintf (file, "%u,", GET_MODE_SIZE (GET_MODE (op))); fprintf (file, "%u,", GET_MODE_SIZE (GET_MODE (op)));
asm_print_register (file, REGNO (XEXP (base, 0))); asm_print_register (file, REGNO (XEXP (base, 0)));
asm_fprintf (file, "-"); fprintf (file, "-");
} }
else else
abort (); abort ();
...@@ -2225,9 +2225,9 @@ print_operand (file, op, letter) ...@@ -2225,9 +2225,9 @@ print_operand (file, op, letter)
case POST_INC: case POST_INC:
if (TARGET_M6812) if (TARGET_M6812)
{ {
asm_fprintf (file, "%u,", GET_MODE_SIZE (GET_MODE (op))); fprintf (file, "%u,", GET_MODE_SIZE (GET_MODE (op)));
asm_print_register (file, REGNO (XEXP (base, 0))); asm_print_register (file, REGNO (XEXP (base, 0)));
asm_fprintf (file, "+"); fprintf (file, "+");
} }
else else
abort (); abort ();
...@@ -2236,7 +2236,7 @@ print_operand (file, op, letter) ...@@ -2236,7 +2236,7 @@ print_operand (file, op, letter)
case PRE_INC: case PRE_INC:
if (TARGET_M6812) if (TARGET_M6812)
{ {
asm_fprintf (file, "%u,+", GET_MODE_SIZE (GET_MODE (op))); fprintf (file, "%u,+", GET_MODE_SIZE (GET_MODE (op)));
asm_print_register (file, REGNO (XEXP (base, 0))); asm_print_register (file, REGNO (XEXP (base, 0)));
} }
else else
...@@ -2277,11 +2277,11 @@ print_operand (file, op, letter) ...@@ -2277,11 +2277,11 @@ print_operand (file, op, letter)
need_parenthesize = must_parenthesize (op); need_parenthesize = must_parenthesize (op);
if (need_parenthesize) if (need_parenthesize)
asm_fprintf (file, "("); fprintf (file, "(");
output_addr_const (file, op); output_addr_const (file, op);
if (need_parenthesize) if (need_parenthesize)
asm_fprintf (file, ")"); fprintf (file, ")");
} }
} }
...@@ -2350,7 +2350,7 @@ print_operand_address (file, addr) ...@@ -2350,7 +2350,7 @@ print_operand_address (file, addr)
if (!REG_P (addr) || !REG_OK_FOR_BASE_STRICT_P (addr)) if (!REG_P (addr) || !REG_OK_FOR_BASE_STRICT_P (addr))
abort (); abort ();
asm_fprintf (file, "0,"); fprintf (file, "0,");
asm_print_register (file, REGNO (addr)); asm_print_register (file, REGNO (addr));
break; break;
...@@ -2361,7 +2361,7 @@ print_operand_address (file, addr) ...@@ -2361,7 +2361,7 @@ print_operand_address (file, addr)
case PRE_DEC: case PRE_DEC:
if (TARGET_M6812) if (TARGET_M6812)
{ {
asm_fprintf (file, "%u,-", GET_MODE_SIZE (GET_MODE (addr))); fprintf (file, "%u,-", GET_MODE_SIZE (GET_MODE (addr)));
asm_print_register (file, REGNO (XEXP (base, 0))); asm_print_register (file, REGNO (XEXP (base, 0)));
} }
else else
...@@ -2371,9 +2371,9 @@ print_operand_address (file, addr) ...@@ -2371,9 +2371,9 @@ print_operand_address (file, addr)
case POST_DEC: case POST_DEC:
if (TARGET_M6812) if (TARGET_M6812)
{ {
asm_fprintf (file, "%u,", GET_MODE_SIZE (GET_MODE (addr))); fprintf (file, "%u,", GET_MODE_SIZE (GET_MODE (addr)));
asm_print_register (file, REGNO (XEXP (base, 0))); asm_print_register (file, REGNO (XEXP (base, 0)));
asm_fprintf (file, "-"); fprintf (file, "-");
} }
else else
abort (); abort ();
...@@ -2382,9 +2382,9 @@ print_operand_address (file, addr) ...@@ -2382,9 +2382,9 @@ print_operand_address (file, addr)
case POST_INC: case POST_INC:
if (TARGET_M6812) if (TARGET_M6812)
{ {
asm_fprintf (file, "%u,", GET_MODE_SIZE (GET_MODE (addr))); fprintf (file, "%u,", GET_MODE_SIZE (GET_MODE (addr)));
asm_print_register (file, REGNO (XEXP (base, 0))); asm_print_register (file, REGNO (XEXP (base, 0)));
asm_fprintf (file, "+"); fprintf (file, "+");
} }
else else
abort (); abort ();
...@@ -2393,7 +2393,7 @@ print_operand_address (file, addr) ...@@ -2393,7 +2393,7 @@ print_operand_address (file, addr)
case PRE_INC: case PRE_INC:
if (TARGET_M6812) if (TARGET_M6812)
{ {
asm_fprintf (file, "%u,+", GET_MODE_SIZE (GET_MODE (addr))); fprintf (file, "%u,+", GET_MODE_SIZE (GET_MODE (addr)));
asm_print_register (file, REGNO (XEXP (base, 0))); asm_print_register (file, REGNO (XEXP (base, 0)));
} }
else else
...@@ -2403,11 +2403,11 @@ print_operand_address (file, addr) ...@@ -2403,11 +2403,11 @@ print_operand_address (file, addr)
default: default:
need_parenthesis = must_parenthesize (base); need_parenthesis = must_parenthesize (base);
if (need_parenthesis) if (need_parenthesis)
asm_fprintf (file, "("); fprintf (file, "(");
output_addr_const (file, base); output_addr_const (file, base);
if (need_parenthesis) if (need_parenthesis)
asm_fprintf (file, ")"); fprintf (file, ")");
break; break;
} }
break; break;
...@@ -2425,13 +2425,13 @@ print_operand_address (file, addr) ...@@ -2425,13 +2425,13 @@ print_operand_address (file, addr)
need_parenthesis = must_parenthesize (addr); need_parenthesis = must_parenthesize (addr);
if (need_parenthesis) if (need_parenthesis)
asm_fprintf (file, "("); fprintf (file, "(");
output_addr_const (file, base); output_addr_const (file, base);
asm_fprintf (file, "+"); fprintf (file, "+");
output_addr_const (file, offset); output_addr_const (file, offset);
if (need_parenthesis) if (need_parenthesis)
asm_fprintf (file, ")"); fprintf (file, ")");
} }
else if (REG_P (base) && REG_OK_FOR_BASE_STRICT_P (base)) else if (REG_P (base) && REG_OK_FOR_BASE_STRICT_P (base))
{ {
...@@ -2440,7 +2440,7 @@ print_operand_address (file, addr) ...@@ -2440,7 +2440,7 @@ print_operand_address (file, addr)
if (TARGET_M6812) if (TARGET_M6812)
{ {
asm_print_register (file, REGNO (offset)); asm_print_register (file, REGNO (offset));
asm_fprintf (file, ","); fprintf (file, ",");
asm_print_register (file, REGNO (base)); asm_print_register (file, REGNO (base));
} }
else else
...@@ -2450,12 +2450,12 @@ print_operand_address (file, addr) ...@@ -2450,12 +2450,12 @@ print_operand_address (file, addr)
{ {
need_parenthesis = must_parenthesize (offset); need_parenthesis = must_parenthesize (offset);
if (need_parenthesis) if (need_parenthesis)
asm_fprintf (file, "("); fprintf (file, "(");
output_addr_const (file, offset); output_addr_const (file, offset);
if (need_parenthesis) if (need_parenthesis)
asm_fprintf (file, ")"); fprintf (file, ")");
asm_fprintf (file, ","); fprintf (file, ",");
asm_print_register (file, REGNO (base)); asm_print_register (file, REGNO (base));
} }
} }
...@@ -2469,17 +2469,17 @@ print_operand_address (file, addr) ...@@ -2469,17 +2469,17 @@ print_operand_address (file, addr)
if (GET_CODE (addr) == CONST_INT if (GET_CODE (addr) == CONST_INT
&& INTVAL (addr) < 0x8000 && INTVAL (addr) >= -0x8000) && INTVAL (addr) < 0x8000 && INTVAL (addr) >= -0x8000)
{ {
asm_fprintf (file, "%d", INTVAL (addr)); fprintf (file, HOST_WIDE_INT_PRINT_DEC, INTVAL (addr));
} }
else else
{ {
need_parenthesis = must_parenthesize (addr); need_parenthesis = must_parenthesize (addr);
if (need_parenthesis) if (need_parenthesis)
asm_fprintf (file, "("); fprintf (file, "(");
output_addr_const (file, addr); output_addr_const (file, addr);
if (need_parenthesis) if (need_parenthesis)
asm_fprintf (file, ")"); fprintf (file, ")");
} }
break; break;
} }
......
...@@ -1135,7 +1135,7 @@ typedef struct m68hc11_args ...@@ -1135,7 +1135,7 @@ typedef struct m68hc11_args
/* Output assembler code to FILE to increment profiler label # LABELNO /* Output assembler code to FILE to increment profiler label # LABELNO
for profiling a function entry. */ for profiling a function entry. */
#define FUNCTION_PROFILER(FILE, LABELNO) \ #define FUNCTION_PROFILER(FILE, LABELNO) \
asm_fprintf (FILE, "\tldy\t.LP%d\n\tjsr mcount\n", (LABELNO)) fprintf (FILE, "\tldy\t.LP%d\n\tjsr mcount\n", (LABELNO))
/* Length in units of the trampoline for entering a nested function. */ /* Length in units of the trampoline for entering a nested function. */
#define TRAMPOLINE_SIZE (TARGET_M6811 ? 11 : 9) #define TRAMPOLINE_SIZE (TARGET_M6811 ? 11 : 9)
...@@ -1650,18 +1650,18 @@ do { \ ...@@ -1650,18 +1650,18 @@ do { \
/* This is how to output an element of a case-vector that is relative. */ /* This is how to output an element of a case-vector that is relative. */
#define ASM_OUTPUT_ADDR_DIFF_ELT(FILE, BODY, VALUE, REL) \ #define ASM_OUTPUT_ADDR_DIFF_ELT(FILE, BODY, VALUE, REL) \
asm_fprintf (FILE, "\t%s\tL%d-L%d\n", integer_asm_op (2, TRUE), VALUE, REL) fprintf (FILE, "\t%s\tL%d-L%d\n", integer_asm_op (2, TRUE), VALUE, REL)
/* This is how to output an element of a case-vector that is absolute. */ /* This is how to output an element of a case-vector that is absolute. */
#define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \ #define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \
asm_fprintf (FILE, "\t%s\t.L%d\n", integer_asm_op (2, TRUE), VALUE) fprintf (FILE, "\t%s\t.L%d\n", integer_asm_op (2, TRUE), VALUE)
/* This is how to output an assembler line that says to advance the /* This is how to output an assembler line that says to advance the
location counter to a multiple of 2**LOG bytes. */ location counter to a multiple of 2**LOG bytes. */
#define ASM_OUTPUT_ALIGN(FILE,LOG) \ #define ASM_OUTPUT_ALIGN(FILE,LOG) \
do { \ do { \
if ((LOG) > 1) \ if ((LOG) > 1) \
asm_fprintf ((FILE), "%s\n", ALIGN_ASM_OP); \ fprintf ((FILE), "%s\n", ALIGN_ASM_OP); \
} while (0) } while (0)
......
...@@ -146,6 +146,6 @@ do { \ ...@@ -146,6 +146,6 @@ do { \
#undef ASM_OUTPUT_INTERNAL_LABEL #undef ASM_OUTPUT_INTERNAL_LABEL
#define ASM_OUTPUT_INTERNAL_LABEL(FILE,PREFIX,NUM) \ #define ASM_OUTPUT_INTERNAL_LABEL(FILE,PREFIX,NUM) \
if (flag_pic && !strcmp(PREFIX,"LC")) \ if (flag_pic && !strcmp(PREFIX,"LC")) \
asm_fprintf (FILE, "%s%%%d:\n", PREFIX, NUM); \ fprintf (FILE, "%s%%%d:\n", PREFIX, NUM); \
else \ else \
asm_fprintf (FILE, "%0L%s%d:\n", PREFIX, NUM) asm_fprintf (FILE, "%0L%s%d:\n", PREFIX, NUM)
...@@ -103,6 +103,6 @@ do { \ ...@@ -103,6 +103,6 @@ do { \
#undef ASM_OUTPUT_INTERNAL_LABEL #undef ASM_OUTPUT_INTERNAL_LABEL
#define ASM_OUTPUT_INTERNAL_LABEL(FILE,PREFIX,NUM) \ #define ASM_OUTPUT_INTERNAL_LABEL(FILE,PREFIX,NUM) \
if (flag_pic && !strcmp(PREFIX,"LC")) \ if (flag_pic && !strcmp(PREFIX,"LC")) \
asm_fprintf (FILE, "%s%%%d:\n", PREFIX, NUM); \ fprintf (FILE, "%s%%%d:\n", PREFIX, NUM); \
else \ else \
asm_fprintf (FILE, "%0L%s%d:\n", PREFIX, NUM) asm_fprintf (FILE, "%0L%s%d:\n", PREFIX, NUM)
...@@ -279,12 +279,14 @@ m68k_output_function_prologue (stream, size) ...@@ -279,12 +279,14 @@ m68k_output_function_prologue (stream, size)
{ {
/* on the 68040, pea + move is faster than link.w 0 */ /* on the 68040, pea + move is faster than link.w 0 */
#ifdef MOTOROLA #ifdef MOTOROLA
asm_fprintf (stream, "\tpea (%s)\n\tmove.l %s,%s\n", fprintf (stream, "\tpea (%s)\n\tmove.l %s,%s\n",
reg_names[FRAME_POINTER_REGNUM], reg_names[STACK_POINTER_REGNUM], reg_names[FRAME_POINTER_REGNUM],
reg_names[STACK_POINTER_REGNUM],
reg_names[FRAME_POINTER_REGNUM]); reg_names[FRAME_POINTER_REGNUM]);
#else #else
asm_fprintf (stream, "\tpea %s@\n\tmovel %s,%s\n", fprintf (stream, "\tpea %s@\n\tmovel %s,%s\n",
reg_names[FRAME_POINTER_REGNUM], reg_names[STACK_POINTER_REGNUM], reg_names[FRAME_POINTER_REGNUM],
reg_names[STACK_POINTER_REGNUM],
reg_names[FRAME_POINTER_REGNUM]); reg_names[FRAME_POINTER_REGNUM]);
#endif #endif
} }
...@@ -778,7 +780,7 @@ m68k_output_function_epilogue (stream, size) ...@@ -778,7 +780,7 @@ m68k_output_function_epilogue (stream, size)
{ {
/* Output just a no-op so that debuggers don't get confused /* Output just a no-op so that debuggers don't get confused
about which function the pc is in at this address. */ about which function the pc is in at this address. */
asm_fprintf (stream, "\tnop\n"); fprintf (stream, "\tnop\n");
return; return;
} }
...@@ -878,7 +880,7 @@ m68k_output_function_epilogue (stream, size) ...@@ -878,7 +880,7 @@ m68k_output_function_epilogue (stream, size)
reg_names[FRAME_POINTER_REGNUM], reg_names[FRAME_POINTER_REGNUM],
reg_names[i]); reg_names[i]);
#else #else
asm_fprintf (stream, "\tmovel %s@(-%d),%s\n", fprintf (stream, "\tmovel %s@(-%d),%s\n",
reg_names[FRAME_POINTER_REGNUM], reg_names[FRAME_POINTER_REGNUM],
offset + fsize, reg_names[i]); offset + fsize, reg_names[i]);
#endif #endif
...@@ -990,12 +992,12 @@ m68k_output_function_epilogue (stream, size) ...@@ -990,12 +992,12 @@ m68k_output_function_epilogue (stream, size)
else else
{ {
#ifdef MOTOROLA #ifdef MOTOROLA
asm_fprintf (stream, "\tfpmovd -%d(%s), %s\n", fprintf (stream, "\tfpmovd -%d(%s), %s\n",
fpoffset + fsize, fpoffset + fsize,
reg_names[FRAME_POINTER_REGNUM], reg_names[FRAME_POINTER_REGNUM],
reg_names[regno]); reg_names[regno]);
#else #else
asm_fprintf (stream, "\tfpmoved %s@(-%d), %s\n", fprintf (stream, "\tfpmoved %s@(-%d), %s\n",
reg_names[FRAME_POINTER_REGNUM], reg_names[FRAME_POINTER_REGNUM],
fpoffset + fsize, reg_names[regno]); fpoffset + fsize, reg_names[regno]);
#endif #endif
...@@ -2959,7 +2961,7 @@ print_operand (file, op, letter) ...@@ -2959,7 +2961,7 @@ print_operand (file, op, letter)
if (letter == '.') if (letter == '.')
{ {
#if defined (MOTOROLA) && !defined (CRDS) #if defined (MOTOROLA) && !defined (CRDS)
asm_fprintf (file, "."); fprintf (file, ".");
#endif #endif
} }
else if (letter == '#') else if (letter == '#')
......
...@@ -785,13 +785,13 @@ mmix_asm_output_mi_thunk (stream, fndecl, delta, func) ...@@ -785,13 +785,13 @@ mmix_asm_output_mi_thunk (stream, fndecl, delta, func)
const char *regname = reg_names[MMIX_FIRST_INCOMING_ARG_REGNUM]; const char *regname = reg_names[MMIX_FIRST_INCOMING_ARG_REGNUM];
if (delta >= 0 && delta < 65536) if (delta >= 0 && delta < 65536)
asm_fprintf (stream, "\tINCL %s,%d\n", delta, regname); fprintf (stream, "\tINCL %s,%d\n", regname, delta);
else if (delta < 0 && delta >= -255) else if (delta < 0 && delta >= -255)
asm_fprintf (stream, "\tSUBU %s,%s,%d\n", regname, regname, -delta); fprintf (stream, "\tSUBU %s,%s,%d\n", regname, regname, -delta);
else else
{ {
mmix_output_register_setting (stream, 255, delta, 1); mmix_output_register_setting (stream, 255, delta, 1);
asm_fprintf (stream, "\tADDU %s,%s,$255\n", regname, regname); fprintf (stream, "\tADDU %s,%s,$255\n", regname, regname);
} }
fprintf (stream, "\tJMP "); fprintf (stream, "\tJMP ");
...@@ -1539,9 +1539,9 @@ mmix_asm_weaken_label (stream, name) ...@@ -1539,9 +1539,9 @@ mmix_asm_weaken_label (stream, name)
FILE * stream ATTRIBUTE_UNUSED; FILE * stream ATTRIBUTE_UNUSED;
const char * name ATTRIBUTE_UNUSED; const char * name ATTRIBUTE_UNUSED;
{ {
asm_fprintf (stream, "\t.weak "); fprintf (stream, "\t.weak ");
assemble_name (stream, name); assemble_name (stream, name);
asm_fprintf (stream, " ! mmixal-incompatible\n"); fprintf (stream, " ! mmixal-incompatible\n");
} }
/* MAKE_DECL_ONE_ONLY. */ /* MAKE_DECL_ONE_ONLY. */
......
...@@ -863,7 +863,7 @@ struct cum_arg { int nbytes; }; ...@@ -863,7 +863,7 @@ struct cum_arg { int nbytes; };
/* This is how to output an element of a case-vector that is absolute. */ /* This is how to output an element of a case-vector that is absolute. */
#define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \ #define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \
asm_fprintf (FILE, "\t%s .L%d\n", ".long", VALUE) fprintf (FILE, "\t%s .L%d\n", ".long", VALUE)
/* This is how to output an element of a case-vector that is relative. */ /* This is how to output an element of a case-vector that is relative. */
......
...@@ -953,7 +953,7 @@ struct cum_arg {int nbytes; }; ...@@ -953,7 +953,7 @@ struct cum_arg {int nbytes; };
/* This is how to output an element of a case-vector that is absolute. */ /* This is how to output an element of a case-vector that is absolute. */
#define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \ #define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \
asm_fprintf (FILE, "\t%s .L%d\n", ".long", VALUE) fprintf (FILE, "\t%s .L%d\n", ".long", VALUE)
/* This is how to output an element of a case-vector that is relative. */ /* This is how to output an element of a case-vector that is relative. */
......
...@@ -1238,7 +1238,7 @@ zbss_section () \ ...@@ -1238,7 +1238,7 @@ zbss_section () \
/* This is how to output an element of a case-vector that is absolute. */ /* This is how to output an element of a case-vector that is absolute. */
#define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \ #define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE) \
asm_fprintf (FILE, "\t%s .L%d\n", \ fprintf (FILE, "\t%s .L%d\n", \
(TARGET_BIG_SWITCH ? ".long" : ".short"), VALUE) (TARGET_BIG_SWITCH ? ".long" : ".short"), VALUE)
/* This is how to output an element of a case-vector that is relative. */ /* This is how to output an element of a case-vector that is relative. */
......
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