]>
git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/config/i386/vxworks.h
1 /* IA32 VxWorks target definitions for GNU compiler.
2 Copyright (C) 2003-2017 Free Software Foundation, Inc.
3 Updated by CodeSourcery, LLC.
5 This file is part of GCC.
7 GCC 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 3, or (at your option)
12 GCC 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 GCC; see the file COPYING3. If not see
19 <http://www.gnu.org/licenses/>. */
24 #define ASM_OUTPUT_ALIGNED_BSS(FILE, DECL, NAME, SIZE, ALIGN) \
25 asm_output_aligned_bss (FILE, DECL, NAME, SIZE, ALIGN)
27 /* VxWorks uses the same ABI as Solaris 2, so use i386/sol2.h version. */
29 #undef TARGET_SUBTARGET_DEFAULT
30 #define TARGET_SUBTARGET_DEFAULT \
31 (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_VECT8_RETURNS)
33 /* Provide our target specific DBX_REGISTER_NUMBER. VxWorks relies on
34 the SVR4 numbering. */
36 #undef DBX_REGISTER_NUMBER
37 #define DBX_REGISTER_NUMBER(n) \
38 (TARGET_64BIT ? dbx64_register_map[n] : svr4_dbx_register_map[n])
40 #define TARGET_OS_CPP_BUILTINS() \
43 VXWORKS_OS_CPP_BUILTINS (); \
45 builtin_define ("CPU=I80386"); \
46 else if (TARGET_486) \
47 builtin_define ("CPU=I80486"); \
48 else if (TARGET_PENTIUM) \
50 builtin_define ("CPU=PENTIUM"); \
51 builtin_define ("CPU_VARIANT=PENTIUM"); \
53 else if (TARGET_PENTIUMPRO) \
55 builtin_define ("CPU=PENTIUM2"); \
56 builtin_define ("CPU_VARIANT=PENTIUMPRO"); \
58 else if (TARGET_PENTIUM4) \
60 builtin_define ("CPU=PENTIUM4"); \
61 builtin_define ("CPU_VARIANT=PENTIUM4"); \
63 else if (TARGET_64BIT) \
64 builtin_define ("CPU=X86_64"); \
66 builtin_define ("CPU=I80386"); \
71 #define CPP_SPEC VXWORKS_ADDITIONAL_CPP_SPEC
73 #define LIB_SPEC VXWORKS_LIB_SPEC
75 #define STARTFILE_SPEC VXWORKS_STARTFILE_SPEC
77 #define ENDFILE_SPEC VXWORKS_ENDFILE_SPEC
79 #define LINK_SPEC VXWORKS_LINK_SPEC
81 #undef SUBTARGET_SWITCHES
82 #define SUBTARGET_SWITCHES EXTRA_SUBTARGET_SWITCHES
84 #undef SUBTARGET_OVERRIDE_OPTIONS
85 #define SUBTARGET_OVERRIDE_OPTIONS VXWORKS_OVERRIDE_OPTIONS
87 /* No _mcount profiling on VxWorks. */
88 #undef FUNCTION_PROFILER
89 #define FUNCTION_PROFILER(FILE,LABELNO) VXWORKS_FUNCTION_PROFILER(FILE,LABELNO)
91 /* We cannot use PC-relative accesses for VxWorks PIC because there is no
92 fixed gap between segments. */
93 #undef ASM_PREFERRED_EH_DATA_FORMAT
95 /* Define this to be nonzero if static stack checking is supported. */
96 #define STACK_CHECK_STATIC_BUILTIN 1
98 /* This platform supports the probing method of stack checking (RTP mode).
99 8K is reserved in the stack to propagate exceptions in case of overflow.
100 On 64-bit targets, we double that size. */
101 #if TARGET_64BIT_DEFAULT
102 #define STACK_CHECK_PROTECT 16384
104 #define STACK_CHECK_PROTECT 8192