Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
4f529f0a
Commit
4f529f0a
authored
May 28, 1992
by
Richard Stallman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*** empty log message ***
From-SVN: r1112
parent
d7cedf4b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
80 additions
and
0 deletions
+80
-0
gcc/config/i386/sysv4.h
+31
-0
gcc/config/i860/sysv4.h
+49
-0
No files found.
gcc/config/i386/sysv4.h
View file @
4f529f0a
...
...
@@ -22,6 +22,7 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
#include "i386.h"
/* Base i386 target machine definitions */
#include "att386.h"
/* Use the i386 AT&T assembler syntax */
#include "svr4.h"
/* Definitions common to all SVR4 targets */
#include "real.h"
#undef TARGET_VERSION
#define TARGET_VERSION fprintf (stderr, " (i386 System V Release 4)");
...
...
@@ -57,6 +58,36 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
#define CPP_PREDEFINES \
"-Di386 -Dunix -D__svr4__ -Asystem(unix) -Acpu(i386) -Amachine(i386)"
/* If the host and target formats match, output the floats as hex. */
#if HOST_FLOAT_FORMAT == TARGET_FLOAT_FORMAT
#if defined (HOST_WORDS_BIG_ENDIAN) == WORDS_BIG_ENDIAN
/* This is how to output assembly code to define a `float' constant.
We always have to use a .long pseudo-op to do this because the native
SVR4 ELF assembler is buggy and it generates incorrect values when we
try to use the .float pseudo-op instead. */
#undef ASM_OUTPUT_FLOAT
#define ASM_OUTPUT_FLOAT(FILE,VALUE) \
do { long value; \
REAL_VALUE_TO_TARGET_SINGLE ((VALUE), value); \
fprintf((FILE), "%s\t0x%x\n", ASM_LONG, value); \
} while (0)
/* This is how to output assembly code to define a `double' constant.
We always have to use a pair of .long pseudo-ops to do this because
the native SVR4 ELF assembler is buggy and it generates incorrect
values when we try to use the the .double pseudo-op instead. */
#undef ASM_OUTPUT_DOUBLE
#define ASM_OUTPUT_DOUBLE(FILE,VALUE) \
do { long value[2]; \
REAL_VALUE_TO_TARGET_DOUBLE ((VALUE), value); \
fprintf((FILE), "%s\t0x%x\n", ASM_LONG, value[0]); \
fprintf((FILE), "%s\t0x%x\n", ASM_LONG, value[1]); \
} while (0)
#endif
/* word order matches */
#endif
/* HOST_FLOAT_FORMAT == TARGET_FLOAT_FORMAT */
/* Output at beginning of assembler file. */
/* The .file command should always begin the output. */
...
...
gcc/config/i860/sysv4.h
View file @
4f529f0a
...
...
@@ -60,6 +60,55 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
fprintf (FILE, "]@%s", PART_CODE); \
} while (0)
/* If the host and target formats match, output the floats as hex. */
#if HOST_FLOAT_FORMAT == TARGET_FLOAT_FORMAT
#if defined (HOST_WORDS_BIG_ENDIAN) == WORDS_BIG_ENDIAN
/* This is how to output an assembler line defining a `double' constant.
Note that the native i860/svr4 ELF assembler can't properly handle
infinity. It generates an incorrect (non-infinity) value when given
`.double 99e9999' and it doesn't grok `inf' at all. It also mishandles
NaNs and -0.0. */
#undef ASM_OUTPUT_DOUBLE
#define ASM_OUTPUT_DOUBLE(FILE,VALUE) \
{ \
if (REAL_VALUE_ISINF (VALUE) \
|| REAL_VALUE_ISNAN (VALUE) \
|| REAL_VALUE_MINUS_ZERO (VALUE)) \
{ \
long t[2]; \
REAL_VALUE_TO_TARGET_DOUBLE ((VALUE), t); \
fprintf (FILE, "\t.word 0x%lx\n\t.word 0x%lx\n", t[0], t[1]); \
} \
else \
fprintf (FILE, "\t.double 0r%.17g\n", VALUE); \
}
/* This is how to output an assembler line defining a `float' constant.
Note that the native i860/svr4 ELF assembler can't properly handle
infinity. It actually generates an assembly time error when given
`.float 99e9999' and it doesn't grok `inf' at all. It also mishandles
NaNs and -0.0. */
#undef ASM_OUTPUT_FLOAT
#define ASM_OUTPUT_FLOAT(FILE,VALUE) \
{ \
if (REAL_VALUE_ISINF (VALUE) \
|| REAL_VALUE_ISNAN (VALUE) \
|| REAL_VALUE_MINUS_ZERO (VALUE)) \
{ \
long t; \
REAL_VALUE_TO_TARGET_SINGLE ((VALUE), t); \
fprintf (FILE, "\t.word 0x%lx\n", t); \
} \
else \
fprintf (FILE, "\t.single 0r%.9g\n", VALUE); \
}
#endif
/* word order matches */
#endif
/* HOST_FLOAT_FORMAT == TARGET_FLOAT_FORMAT */
#undef ASM_FILE_START
#define ASM_FILE_START(FILE) \
do { output_file_directive (FILE, main_input_filename); \
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment