1/* Copyright (C) 1999-2015 Free Software Foundation, Inc.
2
3This file is part of GCC.
4
5GCC is free software; you can redistribute it and/or modify
6it under the terms of the GNU General Public License as published by
7the Free Software Foundation; either version 3, or (at your option)
8any later version.
9
10GCC is distributed in the hope that it will be useful,
11but WITHOUT ANY WARRANTY; without even the implied warranty of
12MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13GNU General Public License for more details.
14
15You should have received a copy of the GNU General Public License
16along with GCC; see the file COPYING3.  If not see
17<http://www.gnu.org/licenses/>.  */
18
19#undef  ASM_SPEC
20#define ASM_SPEC "\
21%{!G:-G 0} %{G*} %(endian_spec) %{mips1} %{mips2} %{mips3} %{mips4} \
22%{mips32} %{mips32r2} %{mips64} \
23%{mips16:%{!mno-mips16:-mips16}} %{mno-mips16:-no-mips16} \
24%(subtarget_asm_optimizing_spec) \
25%(subtarget_asm_debugging_spec) \
26%{mabi=*} %{!mabi*: %(asm_abi_default_spec)} \
27%{mgp32} %{mgp64} %{march=*} %{mxgot:-xgot} \
28%{mtune=*} \
29%(subtarget_asm_spec)"
30
31#undef LINK_SPEC
32#define LINK_SPEC "\
33%(endian_spec) \
34%{!G:-G 0} %{G*} %{mips1} %{mips2} %{mips3} %{mips4} %{mips32} %{mips64} " \
35VXWORKS_LINK_SPEC
36
37#undef  LIB_SPEC
38#define LIB_SPEC VXWORKS_LIB_SPEC
39#undef  STARTFILE_SPEC
40#define STARTFILE_SPEC VXWORKS_STARTFILE_SPEC
41#undef  ENDFILE_SPEC
42#define ENDFILE_SPEC VXWORKS_ENDFILE_SPEC
43
44#define TARGET_OS_CPP_BUILTINS()                        \
45  do                                                    \
46    {                                                   \
47      if (TARGET_64BIT)					\
48	builtin_define ("CPU=MIPS64");			\
49      else						\
50	builtin_define ("CPU=MIPS32");			\
51      if (TARGET_BIG_ENDIAN)				\
52	builtin_define ("MIPSEB");			\
53      else						\
54	builtin_define ("MIPSEL");			\
55      if (TARGET_SOFT_FLOAT)				\
56	builtin_define ("SOFT_FLOAT");			\
57      VXWORKS_OS_CPP_BUILTINS ();			\
58    }                                                   \
59  while (0)
60
61#undef SUBTARGET_CPP_SPEC
62#define SUBTARGET_CPP_SPEC VXWORKS_ADDITIONAL_CPP_SPEC
63
64/* No sdata.  */
65#undef MIPS_DEFAULT_GVALUE
66#define MIPS_DEFAULT_GVALUE 0
67
68/* No _mcount profiling on VxWorks.  */
69#undef FUNCTION_PROFILER
70#define FUNCTION_PROFILER VXWORKS_FUNCTION_PROFILER
71
72#undef SUBTARGET_ASM_SPEC
73#define SUBTARGET_ASM_SPEC "%{mrtp:%{fPIC|fpic:-mvxworks-pic}}"
74
75#undef SUBTARGET_OVERRIDE_OPTIONS
76#define SUBTARGET_OVERRIDE_OPTIONS VXWORKS_OVERRIDE_OPTIONS
77
78#undef DBX_REGISTER_NUMBER
79