Import gcc-2.8.1.tar.bz2
[official-gcc.git] / gcc / config / mips / osfrose.h
blobf6901e85bcb1346e38156aa27b1faf77efc701f6
1 /* Definitions of target machine for GNU compiler.
2 DECstation (OSF/1 reference port with OSF/rose) version.
3 Copyright (C) 1991, 1992, 1995, 1996 Free Software Foundation, Inc.
5 This file is part of GNU CC.
7 GNU CC is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2, or (at your option)
10 any later version.
12 GNU CC is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with GNU CC; see the file COPYING. If not, write to
19 the Free Software Foundation, 59 Temple Place - Suite 330,
20 Boston, MA 02111-1307, USA. */
22 #define DECSTATION
23 #define OSF_OS
25 #define HALF_PIC_DEBUG TARGET_DEBUG_B_MODE
26 #define HALF_PIC_PREFIX "$Lp."
28 #include "halfpic.h"
30 #define WORD_SWITCH_TAKES_ARG(STR) \
31 (DEFAULT_WORD_SWITCH_TAKES_ARG (STR) || !strcmp (STR, "pic-names"))
33 #define CPP_PREDEFINES "\
34 -DOSF -DOSF1 -Dbsd4_2 -DMIPSEL -Dhost_mips -Dmips -Dunix -DR3000 -DSYSTYPE_BSD \
35 -Asystem(unix) -Asystem(xpg4) -Acpu(mips) -Amachine(mips)"
37 #define SUBTARGET_CPP_SIZE_SPEC "\
38 %{mlong64:-D__PTRDIFF_TYPE__=long\\ int} \
39 %{!mlong64:-D__PTRDIFF_TYPE__=int}"
41 #define SUBTARGET_CPP_SPEC "\
42 %{.S: %{!ansi:%{!traditional:%{!traditional-cpp:%{!ftraditional: -traditional}}}}} \
43 %{.s: %{!ansi:%{!traditional:%{!traditional-cpp:%{!ftraditional: -traditional}}}}}"
45 /* ??? This assumes that GNU as is always used with GNU ld, and MIPS as is
46 always used with MIPS ld. */
47 #define LINK_SPEC "\
48 %{G*} %{EL} %{EB} %{mips1} %{mips2} %{mips3} \
49 %{bestGnum} \
50 %{!mmips-as: \
51 %{v*: -v} \
52 %{!noshrlib: %{pic-none: -noshrlib} %{!pic-none: -warn_nopic}} \
53 %{nostdlib} %{noshrlib} %{glue}}"
55 #define LIB_SPEC "-lc"
57 /* Define this macro meaning that `gcc' should find the library
58 `libgcc.a' by hand, rather than passing the argument `-lgcc' to
59 tell the linker to do the search. */
61 #define LINK_LIBGCC_SPECIAL 1
63 #define STARTFILE_SPEC "%{pg:gcrt0.o%s}%{!pg:%{p:mcrt0.o%s}%{!p:crt0.o%s}}"
65 #define MACHINE_TYPE "DECstation with OSF/rose objects"
67 #ifndef MD_EXEC_PREFIX
68 #define MD_EXEC_PREFIX "/usr/ccs/gcc/"
69 #endif
71 #ifndef MD_STARTFILE_PREFIX
72 #define MD_STARTFILE_PREFIX "/usr/ccs/lib/"
73 #endif
75 /* Turn on -mpic-extern by default. */
76 #define CC1_SPEC "\
77 %{gline:%{!g:%{!g0:%{!g1:%{!g2: -g1}}}}} \
78 %{mips1:-mfp32 -mgp32} %{mips2:-mfp32 -mgp32} %{mips3:-mfp64 -mgp64} \
79 %{G*} \
80 %{pic-none: -mno-half-pic} \
81 %{pic-lib: -mhalf-pic} \
82 %{pic-extern: -mhalf-pic} \
83 %{pic-calls: -mhalf-pic} \
84 %{pic-names*: -mhalf-pic} \
85 %{!pic-*: -mhalf-pic}"
87 /* Specify size_t and wchar_t types. */
88 #define SIZE_TYPE "long unsigned int"
89 #define WCHAR_TYPE "unsigned int"
90 #define WCHAR_TYPE_SIZE BITS_PER_WORD
91 #define MAX_WCHAR_TYPE_SIZE MAX_LONG_TYPE_SIZE
93 /* OSF/1 uses gas, not the mips assembler. */
94 #define TARGET_DEFAULT MASK_GAS
96 /* OSF/rose uses stabs, not ECOFF. */
97 #define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
99 /* enable dwarf debugging for testing */
100 #define DWARF_DEBUGGING_INFO
101 /* This is needed by dwarfout.c. */
102 #define SET_ASM_OP ".set"
104 /* Tell collect that the object format is OSF/rose. */
105 #define OBJECT_FORMAT_ROSE
107 /* Tell collect where the appropriate binaries are. */
108 #define REAL_LD_FILE_NAME "/usr/ccs/gcc/gld"
109 #define REAL_NM_FILE_NAME "/usr/ccs/bin/nm"
110 #define REAL_STRIP_FILE_NAME "/usr/ccs/bin/strip"
112 /* Default to -G 0 unless doing ecoff work. */
113 #define MIPS_DEFAULT_GVALUE ((TARGET_MIPS_AS) ? 8 : 0)
115 /* Use atexit for static constructors/destructors, instead of defining
116 our own exit function. */
117 #define HAVE_ATEXIT
119 /* Generate calls to memcpy, etc., not bcopy, etc. */
120 #define TARGET_MEM_FUNCTIONS
122 /* A C statement to output assembler commands which will identify
123 the object file as having been compiled with GNU CC (or another
124 GNU compiler).
126 If you don't define this macro, the string `gcc2_compiled.:' is
127 output. This string is calculated to define a symbol which, on
128 BSD systems, will never be defined for any other reason. GDB
129 checks for the presence of this symbol when reading the symbol
130 table of an executable.
132 On non-BSD systems, you must arrange communication with GDB in
133 some other fashion. If GDB is not used on your system, you can
134 define this macro with an empty body.
136 On OSF/1, gcc2_compiled. confuses the kernel debugger, so don't
137 put it out. */
139 #define ASM_IDENTIFY_GCC(STREAM)
141 /* Identify the front-end which produced this file. To keep symbol
142 space down, and not confuse kdb, only do this if the language is
143 not C. */
145 #define ASM_IDENTIFY_LANGUAGE(STREAM) \
147 if (strcmp (lang_identify (), "c") != 0) \
148 output_lang_identify (STREAM); \
151 #include "mips/mips.h"