]>
gcc.gnu.org Git - gcc.git/blob - gcc/config/m68k/apollo68.h
1 /* Definitions of target machine for GNU compiler. Apollo 680X0 version.
2 Copyright (C) 1989,1992 Free Software Foundation, Inc.
4 This file is part of GNU CC.
6 GNU CC is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2, or (at your option)
11 GNU CC is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with GNU CC; see the file COPYING. If not, write to
18 the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
20 #include "m68k/m68k.h"
22 /* This symbol may be tested in other files for special Apollo handling */
26 /* See m68k.h. 7 means 68020 with 68881. */
28 #ifndef TARGET_DEFAULT
29 #define TARGET_DEFAULT 7
32 /* Target switches for the Apollo is the same as in m68k.h, except
33 there is no Sun FPA. */
35 #undef TARGET_SWITCHES
36 #define TARGET_SWITCHES \
43 { "soft-float", -0102}, \
44 { "nobitfield", -4}, \
49 { "", TARGET_DEFAULT}}
51 /* Define __HAVE_68881__ in preprocessor,
52 according to the -m flags.
53 This will control the use of inline 68881 insns in certain macros.
54 Also inform the program which CPU this is for. */
56 #if TARGET_DEFAULT & 02
58 /* -m68881 is the default */
60 "%{!msoft-float:%{mfpa:-D__HAVE_FPA__ }%{!mfpa:-D__HAVE_68881__ }}\
61 %{!ansi:%{m68000:-Dmc68010 }%{mc68000:-Dmc68010 }%{!mc68000:%{!m68000:-Dmc68020 }}\
62 %{!ansi:-D_APOLLO_SOURCE}}"
66 /* -msoft-float is the default */
68 "%{m68881:-D__HAVE_68881__ }%{mfpa:-D__HAVE_FPA__ }\
69 %{!ansi:%{m68000:-Dmc68010 }%{mc68000:-Dmc68010 }%{!mc68000:%{!m68000:-Dmc68020 }}\
70 %{!ansi:-D_APOLLO_SOURCE}}"
74 /* Names to predefine in the preprocessor for this target machine. */
75 /* These are the ones defined by Apollo, plus mc68000 for uniformity with
76 GCC on other 68000 systems. */
78 #define CPP_PREDEFINES "-Dapollo -Daegis -Dunix"
80 /* cpp has to support a #sccs directive for the /usr/include files */
82 #define SCCS_DIRECTIVE
84 /* Allow #ident but output nothing for it. */
86 #define IDENT_DIRECTIVE
87 #define ASM_OUTPUT_IDENT(FILE, NAME)
89 /* Allow dollarsigns in identifiers */
91 #define DOLLARS_IN_IDENTIFIERS 2
93 /* -m68000 requires special flags to the assembler. */
96 "%{m68000:-mc68010}%{mc68000:-mc68010}%{!mc68000:%{!m68000:-mc68020}}"
99 Note that includes knowledge of the default specs for gcc, ie. no
100 args translates to the same effect as -m68881 */
102 #if TARGET_DEFAULT & 2
103 /* -m68881 is the default */
104 #define STARTFILE_SPEC \
105 "%{pg:gcrt0.o%s}%{!pg:%{p:mcrt0.o%s}%{!p:crt0.o%s}}"
107 /* -msoft-float is the default */
108 #define STARTFILE_SPEC \
109 "%{pg:gcrt0.o%s}%{!pg:%{p:mcrt0.o%s}%{!p:crt0.o%s}}"
112 /* Specify library to handle `-a' basic block profiling. */
114 #define LIB_SPEC "%{!p:%{!pg:-lc}}%{p:-lc_p}%{pg:-lc_p} \
115 %{a:/usr/lib/bb_link.o} "
117 /* Debugging is not supported yet */
119 #undef DBX_DEBUGGING_INFO
120 #undef SDB_DEBUGGING_INFO
122 /* We have atexit(2). So C++ can use it for global destructors. */
124 #if 0 /* troy@cbme.unsw.edu.au says people are still using sr10.2
125 and it does not support atexit. */
129 /* Every structure or union's size must be a multiple of 2 bytes. */
131 #define STRUCTURE_SIZE_BOUNDARY 16
133 /* Boundary (in *bits*) on which stack pointer should be aligned. */
134 #undef STACK_BOUNDARY
135 #define STACK_BOUNDARY 32
137 /* Functions which return large structures get the address
138 to place the wanted value from a hidden parameter. */
140 #undef PCC_STATIC_STRUCT_RETURN
141 #undef STRUCT_VALUE_REGNUM
142 #define STRUCT_VALUE 0
143 #define STRUCT_VALUE_INCOMING 0
145 /* Specify how to pad function arguments.
146 Arguments are not padded at all; the stack is kept aligned on long
149 #define FUNCTION_ARG_PADDING(mode, size) none
151 /* The definition of this macro imposes a limit on the size of
152 an aggregate object which can be treated as if it were a scalar
155 #define MAX_FIXED_MODE_SIZE BITS_PER_WORD
157 /* The definition of this macro implies that there are cases where
158 a scalar value cannot be returned in registers.
159 For Apollo, anything larger than one integer register is returned
160 using the structure-value mechanism, i.e. objects of DFmode are
161 returned that way. */
163 #define RETURN_IN_MEMORY(type) \
164 (TYPE_MODE (type) == BLKmode \
165 || GET_MODE_SIZE (TYPE_MODE (type)) > UNITS_PER_WORD)
167 /* In order to link with Apollo libraries, we can't prefix external
168 symbols with an underscore. */
170 #undef USER_LABEL_PREFIX
172 /* Use a prefix for local labels, just to be on the save side. */
174 #undef LOCAL_LABEL_PREFIX
175 #define LOCAL_LABEL_PREFIX "."
177 /* Use a register prefix to avoid clashes with external symbols (classic
178 example: `extern char PC;' in termcap). */
180 #undef REGISTER_PREFIX
181 #define REGISTER_PREFIX "%"
183 /* In the machine description we can't use %R, because it will not be seen
184 by ASM_FPRINTF. (Isn't that a design bug?). */
186 #undef REGISTER_PREFIX_MD
187 #define REGISTER_PREFIX_MD "%%"
189 /* config/m68k.md has an explicit reference to the program counter,
190 prefix this by the register prefix. */
192 #define ASM_RETURN_CASE_JUMP return "jmp %%pc@(2,%0:w)"
195 /* Here are the new register names. */
197 #undef REGISTER_NAMES
198 #ifndef SUPPORT_SUN_FPA
199 #define REGISTER_NAMES \
200 {"%d0", "%d1", "%d2", "%d3", "%d4", "%d5", "%d6", "%d7", \
201 "%a0", "%a1", "%a2", "%a3", "%a4", "%a5", "%a6", "%sp", \
202 "%fp0", "%fp1", "%fp2", "%fp3", "%fp4", "%fp5", "%fp6", "%fp7" }
203 #else /* SUPPORTED_SUN_FPA */
204 #define REGISTER_NAMES \
205 {"%d0", "%d1", "%d2", "%d3", "%d4", "%d5", "%d6", "%d7", \
206 "%a0", "%a1", "%a2", "%a3", "%a4", "%a5", "%a6", "%sp", \
207 "%fp0", "%fp1", "%fp2", "%fp3", "%fp4", "%fp5", "%fp6", "%fp7", \
208 "%fpa0", "%fpa1", "%fpa2", "%fpa3", "%fpa4", "%fpa5", "%fpa6", "%fpa7", \
209 "%fpa8", "%fpa9", "%fpa10", "%fpa11", "%fpa12", "%fpa13", "%fpa14", "%fpa15", \
210 "%fpa16", "%fpa17", "%fpa18", "%fpa19", "%fpa20", "%fpa21", "%fpa22", "%fpa23", \
211 "%fpa24", "%fpa25", "%fpa26", "%fpa27", "%fpa28", "%fpa29", "%fpa30", "%fpa31" }
212 #endif /* defined SUPPORT_SUN_FPA */
This page took 0.043333 seconds and 5 git commands to generate.