Mercurial > hg > CbC > CbC_gcc
comparison gcc/config/i386/openbsdelf.h @ 0:a06113de4d67
first commit
author | kent <kent@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Fri, 17 Jul 2009 14:47:48 +0900 |
parents | |
children | 77e2b8dfacca |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:a06113de4d67 |
---|---|
1 /* Configuration for an OpenBSD i386 target. | |
2 | |
3 Copyright (C) 2005, 2007 Free Software Foundation, Inc. | |
4 | |
5 This file is part of GCC. | |
6 | |
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) | |
10 any later version. | |
11 | |
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. | |
16 | |
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/>. */ | |
20 | |
21 /* This gets defined in tm.h->linux.h->svr4.h, and keeps us from using | |
22 libraries compiled with the native cc, so undef it. */ | |
23 #undef NO_DOLLAR_IN_LABEL | |
24 | |
25 /* Override the default comment-starter of "/". */ | |
26 #undef ASM_COMMENT_START | |
27 #define ASM_COMMENT_START "#" | |
28 | |
29 #undef DBX_REGISTER_NUMBER | |
30 #define DBX_REGISTER_NUMBER(n) svr4_dbx_register_map[n] | |
31 | |
32 /* This goes away when the math-emulator is fixed */ | |
33 #undef TARGET_DEFAULT | |
34 #define TARGET_DEFAULT \ | |
35 (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_NO_FANCY_MATH_387) | |
36 | |
37 /* Run-time target specifications */ | |
38 | |
39 #define TARGET_OS_CPP_BUILTINS() \ | |
40 do \ | |
41 { \ | |
42 OPENBSD_OS_CPP_BUILTINS(); \ | |
43 } \ | |
44 while (0) | |
45 | |
46 /* As an elf system, we need crtbegin/crtend stuff. */ | |
47 #undef STARTFILE_SPEC | |
48 #define STARTFILE_SPEC "\ | |
49 %{!shared: %{pg:gcrt0%O%s} %{!pg:%{p:gcrt0%O%s} %{!p:crt0%O%s}} \ | |
50 crtbegin%O%s} %{shared:crtbeginS%O%s}" | |
51 #undef ENDFILE_SPEC | |
52 #define ENDFILE_SPEC "%{!shared:crtend%O%s} %{shared:crtendS%O%s}" | |
53 | |
54 /* Layout of source language data types. */ | |
55 | |
56 /* This must agree with <machine/ansi.h> */ | |
57 #undef SIZE_TYPE | |
58 #define SIZE_TYPE "unsigned int" | |
59 | |
60 #undef PTRDIFF_TYPE | |
61 #define PTRDIFF_TYPE "int" | |
62 | |
63 #undef WCHAR_TYPE | |
64 #define WCHAR_TYPE "int" | |
65 | |
66 #undef WCHAR_TYPE_SIZE | |
67 #define WCHAR_TYPE_SIZE BITS_PER_WORD | |
68 | |
69 /* Assembler format: overall framework. */ | |
70 | |
71 #undef ASM_APP_ON | |
72 #define ASM_APP_ON "#APP\n" | |
73 | |
74 #undef ASM_APP_OFF | |
75 #define ASM_APP_OFF "#NO_APP\n" | |
76 | |
77 #undef SET_ASM_OP | |
78 #define SET_ASM_OP "\t.set\t" | |
79 | |
80 /* The following macros were originally stolen from i386v4.h. | |
81 These have to be defined to get PIC code correct. */ | |
82 | |
83 /* Assembler format: dispatch tables. */ | |
84 | |
85 /* Assembler format: sections. */ | |
86 | |
87 /* Stack & calling: aggregate returns. */ | |
88 | |
89 /* Don't default to pcc-struct-return, because gcc is the only compiler, and | |
90 we want to retain compatibility with older gcc versions. */ | |
91 #define DEFAULT_PCC_STRUCT_RETURN 0 | |
92 | |
93 /* Assembler format: alignment output. */ | |
94 | |
95 #ifdef HAVE_GAS_MAX_SKIP_P2ALIGN | |
96 #define ASM_OUTPUT_MAX_SKIP_ALIGN(FILE,LOG,MAX_SKIP) \ | |
97 if ((LOG) != 0) {\ | |
98 if ((MAX_SKIP) == 0) fprintf ((FILE), "\t.p2align %d\n", (LOG)); \ | |
99 else fprintf ((FILE), "\t.p2align %d,,%d\n", (LOG), (MAX_SKIP)); \ | |
100 } | |
101 #endif | |
102 | |
103 /* Stack & calling: profiling. */ | |
104 | |
105 /* OpenBSD's profiler recovers all information from the stack pointer. | |
106 The icky part is not here, but in machine/profile.h. */ | |
107 #undef FUNCTION_PROFILER | |
108 #define FUNCTION_PROFILER(FILE, LABELNO) \ | |
109 fputs (flag_pic ? "\tcall __mcount@PLT\n": "\tcall __mcount\n", FILE); | |
110 | |
111 /* Assembler format: exception region output. */ | |
112 | |
113 /* our configuration still doesn't handle dwarf2 correctly */ | |
114 #define DWARF2_UNWIND_INFO 0 | |
115 | |
116 /* Assembler format: alignment output. */ | |
117 | |
118 /* Note that we pick up ASM_OUTPUT_MAX_SKIP_ALIGN from i386/gas.h */ | |
119 | |
120 /* Note that we pick up ASM_OUTPUT_MI_THUNK from unix.h. */ | |
121 | |
122 #undef LINK_SPEC | |
123 #define LINK_SPEC \ | |
124 "%{!shared:%{!nostdlib:%{!r*:%{!e*:-e __start}}}} \ | |
125 %{shared:-shared} %{R*} \ | |
126 %{static:-Bstatic} \ | |
127 %{!static:-Bdynamic} \ | |
128 %{assert*} \ | |
129 %{!dynamic-linker:-dynamic-linker /usr/libexec/ld.so}" | |
130 | |
131 #define OBSD_HAS_CORRECT_SPECS |