]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/config/rs6000/linux.h
intrinsic.texi: Add documentaion for eoshift, epsilon, etime, and exit.
[thirdparty/gcc.git] / gcc / config / rs6000 / linux.h
CommitLineData
9a57586f 1/* Definitions of target machine for GNU compiler,
88cad84b 2 for PowerPC machines running Linux.
71625f3d 3 Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
c4db7ecb 4 Free Software Foundation, Inc.
9a57586f
MM
5 Contributed by Michael Meissner (meissner@cygnus.com).
6
5de601cf 7 This file is part of GCC.
9a57586f 8
5de601cf
NC
9 GCC is free software; you can redistribute it and/or modify it
10 under the terms of the GNU General Public License as published
11 by the Free Software Foundation; either version 2, or (at your
12 option) any later version.
9a57586f 13
5de601cf
NC
14 GCC is distributed in the hope that it will be useful, but WITHOUT
15 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
16 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
17 License for more details.
9a57586f 18
5de601cf
NC
19 You should have received a copy of the GNU General Public License
20 along with GCC; see the file COPYING. If not, write to the
39d14dda
KC
21 Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston,
22 MA 02110-1301, USA. */
9a57586f 23
bd227acc
FS
24#undef MD_EXEC_PREFIX
25#undef MD_STARTFILE_PREFIX
26
bf276e5c
AM
27/* Linux doesn't support saving and restoring 64-bit regs in a 32-bit
28 process. */
29#define OS_MISSING_POWERPC64 1
30
71625f3d
AM
31/* We use glibc _mcount for profiling. */
32#define NO_PROFILE_COUNTERS 1
33
bf276e5c
AM
34/* glibc has float and long double forms of math functions. */
35#undef TARGET_C99_FUNCTIONS
36#define TARGET_C99_FUNCTIONS 1
37
5de601cf 38#undef TARGET_OS_CPP_BUILTINS
c4ad648e
AM
39#define TARGET_OS_CPP_BUILTINS() \
40 do \
41 { \
42 builtin_define_std ("PPC"); \
43 builtin_define_std ("powerpc"); \
44 builtin_assert ("cpu=powerpc"); \
45 builtin_assert ("machine=powerpc"); \
46 TARGET_OS_SYSV_CPP_BUILTINS (); \
47 } \
7990b46f 48 while (0)
9a57586f 49
373107aa
FS
50#undef CPP_OS_DEFAULT_SPEC
51#define CPP_OS_DEFAULT_SPEC "%(cpp_os_linux)"
52
437558e8
FS
53/* The GNU C++ standard library currently requires _GNU_SOURCE being
54 defined on glibc-based systems. This temporary hack accomplishes this,
55 it should go away as soon as libstdc++-v3 has a real fix. */
5de601cf 56#undef CPLUSPLUS_CPP_SPEC
437558e8
FS
57#define CPLUSPLUS_CPP_SPEC "-D_GNU_SOURCE %(cpp)"
58
5de601cf 59#undef LINK_SHLIB_SPEC
362c63a5 60#define LINK_SHLIB_SPEC "%{shared:-shared} %{!shared: %{static:-static}}"
9a57586f
MM
61
62#undef LIB_DEFAULT_SPEC
0bc25b2b 63#define LIB_DEFAULT_SPEC "%(lib_linux)"
9a57586f
MM
64
65#undef STARTFILE_DEFAULT_SPEC
0bc25b2b 66#define STARTFILE_DEFAULT_SPEC "%(startfile_linux)"
9a57586f
MM
67
68#undef ENDFILE_DEFAULT_SPEC
0bc25b2b 69#define ENDFILE_DEFAULT_SPEC "%(endfile_linux)"
9a57586f 70
362c63a5
GK
71#undef LINK_START_DEFAULT_SPEC
72#define LINK_START_DEFAULT_SPEC "%(link_start_linux)"
73
74#undef LINK_OS_DEFAULT_SPEC
75#define LINK_OS_DEFAULT_SPEC "%(link_os_linux)"
76
42df2193
JJ
77#define LINK_GCC_C_SEQUENCE_SPEC \
78 "%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}"
79
8efcd34f
AM
80/* Use --as-needed -lgcc_s for eh support. */
81#ifdef HAVE_LD_AS_NEEDED
82#define USE_LD_AS_NEEDED 1
83#endif
84
5de601cf 85#undef TARGET_VERSION
956d6950 86#define TARGET_VERSION fprintf (stderr, " (PowerPC GNU/Linux)");
3807773b 87
832ea3b3 88/* Override rs6000.h definition. */
5de601cf 89#undef ASM_APP_ON
832ea3b3
FS
90#define ASM_APP_ON "#APP\n"
91
92/* Override rs6000.h definition. */
5de601cf 93#undef ASM_APP_OFF
832ea3b3
FS
94#define ASM_APP_OFF "#NO_APP\n"
95
6fa3f289
ZW
96/* For backward compatibility, we must continue to use the AIX
97 structure return convention. */
5de601cf 98#undef DRAFT_V4_STRUCT_RET
6fa3f289
ZW
99#define DRAFT_V4_STRUCT_RET 1
100
9739c90c
JJ
101/* We are 32-bit all the time, so optimize a little. */
102#undef TARGET_64BIT
103#define TARGET_64BIT 0
104
84dcde01
AM
105/* We don't need to generate entries in .fixup, except when
106 -mrelocatable or -mrelocatable-lib is given. */
9739c90c 107#undef RELOCATABLE_NEEDS_FIXUP
84dcde01
AM
108#define RELOCATABLE_NEEDS_FIXUP \
109 (target_flags & target_flags_explicit & MASK_RELOCATABLE)
9739c90c 110
a5fe455b 111#define TARGET_ASM_FILE_END file_end_indicate_exec_stack
3edc56a9 112
c2cd64b5
JJ
113#define TARGET_HAS_F_SETLKW
114
8662eb14 115#define MD_UNWIND_SUPPORT "config/rs6000/linux-unwind.h"