Commit 1861262d by Richard Stallman

(ASM_OUTPUT_FLOAT, ASM_OUTPUT_DOUBLE)

(ASM_OUTPUT_FLOAT, ASM_OUTPUT_DOUBLE)
(ASM_OUTPUT_DOUBLE_OPERAND): Use REAL_VALUE... macros.
(ASM_OUTPUT_LONG_DOUBLE): New definition.
(ASM_OUTPUT_FLOAT_OPERAND): New macro.
(PRINT_OPERAND_PRINT_FLOAT): Deleted.

From-SVN: r3976
parent 04ea6a84
/* Definitions of target machine for GNU compiler for m68k targets using /* Definitions of target machine for GNU compiler for m68k targets using
assemblers derived from AT&T "SGS" releases. assemblers derived from AT&T "SGS" releases.
Copyright (C) 1991 Free Software Foundation, Inc. Copyright (C) 1991, 1993 Free Software Foundation, Inc.
Written by Fred Fish (fnf@cygnus.com) Written by Fred Fish (fnf@cygnus.com)
...@@ -119,23 +119,31 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ ...@@ -119,23 +119,31 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
output_addr_const ((FILE), (VALUE)), \ output_addr_const ((FILE), (VALUE)), \
fprintf ((FILE), "\n")) fprintf ((FILE), "\n"))
#undef ASM_OUTPUT_LONG_DOUBLE
#define ASM_OUTPUT_LONG_DOUBLE(FILE,VALUE) \
do { long l[3]; \
REAL_VALUE_TO_TARGET_LONG_DOUBLE (VALUE, l); \
fprintf ((FILE), "\t%s 0x%x,0x%x,0x%x\n", LONG_ASM_OP, \
l[0], l[1], l[2]); \
} while (0)
/* This is how to output an assembler line defining a `double' constant. */ /* This is how to output an assembler line defining a `double' constant. */
#undef ASM_OUTPUT_DOUBLE #undef ASM_OUTPUT_DOUBLE
#define ASM_OUTPUT_DOUBLE(FILE,VALUE) \ #define ASM_OUTPUT_DOUBLE(FILE,VALUE) \
do { union { double d; long l[2]; } tem; \ do { long l[2]; \
tem.d = (VALUE); \ REAL_VALUE_TO_TARGET_DOUBLE (VALUE, l); \
fprintf((FILE), "\t%s 0x%x,0x%x\n", LONG_ASM_OP, \ fprintf ((FILE), "\t%s 0x%x,0x%x\n", LONG_ASM_OP, \
tem.l[0], tem.l[1]); \ l[0], l[1]); \
} while (0) } while (0)
/* This is how to output an assembler line defining a `float' constant. */ /* This is how to output an assembler line defining a `float' constant. */
#undef ASM_OUTPUT_FLOAT #undef ASM_OUTPUT_FLOAT
#define ASM_OUTPUT_FLOAT(FILE,VALUE) \ #define ASM_OUTPUT_FLOAT(FILE,VALUE) \
do { union { float f; long l;} tem; \ do { long l; \
tem.f = (VALUE); \ REAL_VALUE_TO_TARGET_SINGLE (VALUE, l); \
fprintf ((FILE), "\t%s 0x%x\n", LONG_ASM_OP, tem.l); \ fprintf ((FILE), "\t%s 0x%x\n", LONG_ASM_OP, l); \
} while (0) } while (0)
/* 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
...@@ -209,15 +217,19 @@ do { union { float f; long l;} tem; \ ...@@ -209,15 +217,19 @@ do { union { float f; long l;} tem; \
#define ASM_OUTPUT_REG_POP(FILE,REGNO) \ #define ASM_OUTPUT_REG_POP(FILE,REGNO) \
asm_fprintf (FILE, "\t%Omove.l (%Rsp)+,%s\n", reg_names[REGNO]) asm_fprintf (FILE, "\t%Omove.l (%Rsp)+,%s\n", reg_names[REGNO])
#undef PRINT_OPERAND_PRINT_FLOAT #undef ASM_OUTPUT_FLOAT_OPERAND
#define PRINT_OPERAND_PRINT_FLOAT(CODE,FILE) \ #define ASM_OUTPUT_FLOAT_OPERAND(CODE,FILE,VALUE) \
asm_fprintf ((FILE), "%I0x%x", u1.i); do { long l; \
REAL_VALUE_TO_TARGET_SINGLE (VALUE, l); \
asm_fprintf ((FILE), "%I0x%x", l); \
} while (0)
#undef ASM_OUTPUT_DOUBLE_OPERAND #undef ASM_OUTPUT_DOUBLE_OPERAND
#define ASM_OUTPUT_DOUBLE_OPERAND(FILE,VALUE) \ #define ASM_OUTPUT_DOUBLE_OPERAND(FILE,VALUE) \
do { union real_extract u; \ do { long l[2]; \
u.d = (VALUE); \ REAL_VALUE_TO_TARGET_DOUBLE (VALUE, l); \
asm_fprintf ((FILE),"%I0x%x%08x", u.i[0], u.i[1]); } while (0) asm_fprintf ((FILE), "%I0x%x%08x", l[0], l[1]); \
} while (0)
/* How to output a block of SIZE zero bytes. Note that the `space' pseudo, /* How to output a block of SIZE zero bytes. Note that the `space' pseudo,
when used in the text segment, causes SGS assemblers to output nop insns when used in the text segment, causes SGS assemblers to output nop insns
......
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