Mercurial > hg > CbC > CbC_gcc
comparison gcc/config/i386/linux.h @ 67:f6334be47118
update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
author | nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 22 Mar 2011 17:18:12 +0900 |
parents | b7f97abdc517 |
children | 04ced10e8804 |
comparison
equal
deleted
inserted
replaced
65:65488c3d617d | 67:f6334be47118 |
---|---|
1 /* Definitions for Intel 386 running Linux-based GNU systems with ELF format. | 1 /* Definitions for Intel 386 running Linux-based GNU systems with ELF format. |
2 Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002, 2004, 2005, | 2 Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002, 2004, 2005, |
3 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. | 3 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. |
4 Contributed by Eric Youngdale. | 4 Contributed by Eric Youngdale. |
5 Modified for stabs-in-ELF by H.J. Lu. | 5 Modified for stabs-in-ELF by H.J. Lu. |
6 | 6 |
7 This file is part of GCC. | 7 This file is part of GCC. |
8 | 8 |
83 #define CC1_SPEC "%(cc1_cpu) %{profile:-p}" | 83 #define CC1_SPEC "%(cc1_cpu) %{profile:-p}" |
84 | 84 |
85 /* Provide a LINK_SPEC appropriate for Linux. Here we provide support | 85 /* Provide a LINK_SPEC appropriate for Linux. Here we provide support |
86 for the special GCC options -static and -shared, which allow us to | 86 for the special GCC options -static and -shared, which allow us to |
87 link things in one of these three modes by applying the appropriate | 87 link things in one of these three modes by applying the appropriate |
88 combinations of options at link-time. We like to support here for | 88 combinations of options at link-time. |
89 as many of the other GNU linker options as possible. But I don't | |
90 have the time to search for those flags. I am sure how to add | |
91 support for -soname shared_object_name. H.J. | |
92 | |
93 I took out %{v:%{!V:-V}}. It is too much :-(. They can use | |
94 -Wl,-V. | |
95 | 89 |
96 When the -shared link option is used a final link is not being | 90 When the -shared link option is used a final link is not being |
97 done. */ | 91 done. */ |
98 | |
99 /* If ELF is the default format, we should not use /lib/elf. */ | |
100 | 92 |
101 /* These macros may be overridden in k*bsd-gnu.h and i386/k*bsd-gnu.h. */ | 93 /* These macros may be overridden in k*bsd-gnu.h and i386/k*bsd-gnu.h. */ |
102 #define LINK_EMULATION "elf_i386" | 94 #define LINK_EMULATION "elf_i386" |
103 #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2" | 95 #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2" |
104 | 96 |
105 #undef ASM_SPEC | 97 #undef ASM_SPEC |
106 #define ASM_SPEC \ | 98 #define ASM_SPEC \ |
107 "%{v:-V} %{Qy:} %{!Qn:-Qy} %{n} %{T} %{Ym,*} %{Yd,*} %{Wa,*:%*} --32 \ | 99 "--32 %{!mno-sse2avx:%{mavx:-msse2avx}} %{msse2avx:%{!mavx:-msse2avx}}" |
108 %{!mno-sse2avx:%{mavx:-msse2avx}} %{msse2avx:%{!mavx:-msse2avx}}" | |
109 | 100 |
110 #undef SUBTARGET_EXTRA_SPECS | 101 #undef SUBTARGET_EXTRA_SPECS |
111 #define SUBTARGET_EXTRA_SPECS \ | 102 #define SUBTARGET_EXTRA_SPECS \ |
112 { "link_emulation", LINK_EMULATION },\ | 103 { "link_emulation", LINK_EMULATION },\ |
113 { "dynamic_linker", LINUX_DYNAMIC_LINKER } | 104 { "dynamic_linker", LINUX_DYNAMIC_LINKER } |
114 | 105 |
115 #undef LINK_SPEC | 106 #undef LINK_SPEC |
116 #define LINK_SPEC "-m %(link_emulation) %{shared:-shared} \ | 107 #define LINK_SPEC "-m %(link_emulation) %{shared:-shared} \ |
117 %{!shared: \ | 108 %{!shared: \ |
118 %{!ibcs: \ | 109 %{!static: \ |
119 %{!static: \ | 110 %{rdynamic:-export-dynamic} \ |
120 %{rdynamic:-export-dynamic} \ | 111 -dynamic-linker %(dynamic_linker)} \ |
121 %{!dynamic-linker:-dynamic-linker %(dynamic_linker)}} \ | 112 %{static:-static}}" |
122 %{static:-static}}}" | |
123 | 113 |
124 /* Similar to standard Linux, but adding -ffast-math support. */ | 114 /* Similar to standard Linux, but adding -ffast-math support. */ |
125 #undef ENDFILE_SPEC | 115 #undef ENDFILE_SPEC |
126 #define ENDFILE_SPEC \ | 116 #define ENDFILE_SPEC \ |
127 "%{ffast-math|funsafe-math-optimizations:crtfastmath.o%s} \ | 117 "%{ffast-math|funsafe-math-optimizations:crtfastmath.o%s} \ |
207 #define MD_UNWIND_SUPPORT "config/i386/linux-unwind.h" | 197 #define MD_UNWIND_SUPPORT "config/i386/linux-unwind.h" |
208 | 198 |
209 /* The stack pointer needs to be moved while checking the stack. */ | 199 /* The stack pointer needs to be moved while checking the stack. */ |
210 #define STACK_CHECK_MOVING_SP 1 | 200 #define STACK_CHECK_MOVING_SP 1 |
211 | 201 |
202 /* Static stack checking is supported by means of probes. */ | |
203 #define STACK_CHECK_STATIC_BUILTIN 1 | |
204 | |
212 /* This macro may be overridden in i386/k*bsd-gnu.h. */ | 205 /* This macro may be overridden in i386/k*bsd-gnu.h. */ |
213 #define REG_NAME(reg) reg | 206 #define REG_NAME(reg) reg |
214 | 207 |
215 #ifdef TARGET_LIBC_PROVIDES_SSP | 208 #ifdef TARGET_LIBC_PROVIDES_SSP |
216 /* i386 glibc provides __stack_chk_guard in %gs:0x14. */ | 209 /* i386 glibc provides __stack_chk_guard in %gs:0x14. */ |
217 #define TARGET_THREAD_SSP_OFFSET 0x14 | 210 #define TARGET_THREAD_SSP_OFFSET 0x14 |
211 | |
212 /* We steal the last transactional memory word. */ | |
213 #define TARGET_CAN_SPLIT_STACK | |
214 #define TARGET_THREAD_SPLIT_STACK_OFFSET 0x30 | |
218 #endif | 215 #endif |