OSDN Git Service

* config/rs6000/darwin.h (SUBTARGET_OPTIONS): Move from here, to...
[pf3gnuchains/gcc-fork.git] / gcc / config / rs6000 / vxworks.h
1 /* Definitions of target machine for GNU compiler.  Vxworks PowerPC version.
2    Copyright (C) 1996, 2000, 2002, 2003 Free Software Foundation, Inc.
3
4    This file is part of GCC.
5
6    GCC is free software; you can redistribute it and/or modify it
7    under the terms of the GNU General Public License as published
8    by the Free Software Foundation; either version 2, or (at your
9    option) any later version.
10
11    GCC is distributed in the hope that it will be useful, but WITHOUT
12    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13    or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
14    License for more details.
15
16    You should have received a copy of the GNU General Public License
17    along with GCC; see the file COPYING.  If not, write to the
18    Free Software Foundation, 59 Temple Place - Suite 330, Boston,
19    MA 02111-1307, USA.  */
20
21 #undef  TARGET_OS_CPP_BUILTINS
22 #define TARGET_OS_CPP_BUILTINS()                \
23   do                                            \
24     {                                           \
25       builtin_define ("__vxworks");             \
26       builtin_define ("__vxworks__");           \
27     }                                           \
28   while (0)
29
30 /* We have to kill off the entire specs set created by rs6000/sysv4.h
31    and substitute our own set.  The top level vxworks.h has done some
32    of this for us.  */
33
34 #undef SUBTARGET_EXTRA_SPECS
35 #undef CPP_SPEC
36 #undef CC1_SPEC
37 #undef ASM_SPEC
38
39 #define SUBTARGET_EXTRA_SPECS /* none needed */
40
41 #define CPP_SPEC \
42 "-DCPU_FAMILY=PPC -D__ppc -D__EABI__  \
43  %{t403: -DCPU=PPC403 -D_SOFT_FLOAT ; \
44    t405: -DCPU=PPC405 -D_SOFT_FLOAT ; \
45    t440: -DCPU=PPC440 -D_SOFT_FLOAT ; \
46    t603: -DCPU=PPC603               ; \
47    t604: -DCPU=PPC604               ; \
48    t860: -DCPU=PPC860 -D_SOFT_FLOAT ; \
49        : -DCPU=PPC604}  \
50  %{!msoft-float:-D__hardfp}        \
51  %{fpic|fpie: -D__PIC__=1 -D__pic__=1 ; \
52    fPIC|fPIE: -D__PIC__=2 -D__pic__=2 } \
53  %(cpp_cpu)"
54
55 #define CC1_SPEC \
56 "%{t403: -mcpu=403 -mstrict-align ;                             \
57    t405: -mcpu=405 -mstrict-align ;                             \
58    t440: -mcpu=440 -mstrict-align ;                             \
59    t603: -mcpu=603 -mstrict-align ;                             \
60    t604: -mcpu=604 -mstrict-align ;                             \
61    t860: -mcpu=860                ;                             \
62        : -mcpu=604 -mstrict-align }                             \
63  %{G*} %{mno-sdata:-msdata=none} %{msdata:-msdata=default}      \
64  %{mlittle|mlittle-endian:-mstrict-align}                       \
65  %{profile: -p}                                                 \
66  %{fvec:-maltivec} %{fvec-eabi:-maltivec -mabi=altivec}"
67    
68 #define ASM_SPEC "%(asm_cpu) \
69 %{.s: %{mregnames} %{mno-regnames}} %{.S: %{mregnames} %{mno-regnames}} \
70 %{v:-V} %{Qy:} %{!Qn:-Qy} %{n} %{T} %{Ym,*} %{Yd,*} %{Wa,*:%*} \
71 %{mrelocatable} %{mrelocatable-lib} %{fpic:-K PIC} %{fPIC:-K PIC} -mbig"
72
73 #undef  MULTILIB_DEFAULTS
74 #define MULTILIB_DEFAULTS { "t604" }
75
76 /* We can't use .ctors/.dtors sections.  */
77 #undef TARGET_ASM_OUTPUT_CONSTRUCTOR
78 #undef TARGET_ASM_OUTPUT_DESTRUCTOR
79
80 /* Nor sdata.  */
81 #undef  SDATA_DEFAULT_SIZE
82 #define SDATA_DEFAULT_SIZE 0