/[cmucl]/src/lisp/x86-validate.h
ViewVC logotype

Contents of /src/lisp/x86-validate.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.28 - (show annotations)
Fri Jul 6 08:04:39 2007 UTC (6 years, 9 months ago) by cshapiro
Branch: MAIN
CVS Tags: merged-unicode-utf16-extfmt-2009-06-11, unicode-utf16-extfmt-2009-03-27, snapshot-2007-09, snapshot-2007-08, snapshot-2008-08, snapshot-2008-09, sse2-packed-2008-11-12, snapshot-2008-05, snapshot-2008-06, snapshot-2008-07, snapshot-2008-01, snapshot-2008-02, snapshot-2008-03, unicode-string-buffer-impl-base, sse2-base, unicode-string-buffer-base, sse2-packed-base, amd64-dd-start, release-19f-pre1, snapshot-2008-12, snapshot-2008-11, release-19e, unicode-utf16-sync-2008-12, label-2009-03-16, release-19f-base, merge-sse2-packed, merge-with-19f, unicode-snapshot-2009-05, unicode-snapshot-2009-06, unicode-utf16-sync-2008-07, unicode-utf16-sync-2008-09, unicode-utf16-extfmts-sync-2008-12, snapshot-2008-04, unicode-utf16-sync-label-2009-03-16, RELEASE_19f, release-20a-base, unicode-utf16-char-support-2009-03-26, unicode-utf16-char-support-2009-03-25, unicode-utf16-extfmts-pre-sync-2008-11, snapshot-2008-10, unicode-utf16-sync-2008-11, release-19e-pre1, release-19e-pre2, label-2009-03-25, sse2-checkpoint-2008-10-01, sse2-merge-with-2008-11, sse2-merge-with-2008-10, RELEASE_20a, release-20a-pre1, snapshot-2009-11, snapshot-2009-12, unicode-utf16-extfmt-2009-06-11, portable-clx-import-2009-06-16, unicode-utf16-string-support, release-19e-base, unicode-utf16-base, portable-clx-base, snapshot-2009-08, snapshot-2007-12, snapshot-2007-10, snapshot-2007-11, snapshot-2009-02, snapshot-2009-01, snapshot-2009-07, snapshot-2009-05, snapshot-2009-04, pre-telent-clx
Branch point for: RELEASE-19F-BRANCH, portable-clx-branch, unicode-string-buffer-branch, sse2-packed-branch, RELEASE-20A-BRANCH, amd64-dd-branch, unicode-string-buffer-impl-branch, unicode-utf16-branch, release-19e-branch, sse2-branch, unicode-utf16-extfmt-branch
Changes since 1.27: +4 -4 lines
File MIME type: text/plain
Import x86 Darwin port.
1 /*
2 *
3 * This code was written as part of the CMU Common Lisp project at
4 * Carnegie Mellon University, and has been placed in the public domain.
5 *
6 * $Header: /tiger/var/lib/cvsroots/cmucl/src/lisp/x86-validate.h,v 1.28 2007/07/06 08:04:39 cshapiro Rel $
7 *
8 */
9
10 #ifndef _X86_VALIDATE_H_
11 #define _X86_VALIDATE_H_
12
13 /*
14 * Also look in compiler/x86/parms.lisp for some of the parameters.
15 *
16 * Address map:
17 *
18 * FreeBSD:
19 * 0x00000000->0x0E000000 224M C program and memory allocation.
20 * 0x0E000000->0x10000000 32M Foreign segment.
21 * 0x10000000->0x20000000 256M Read-Only Space.
22 * 0x20000000->0x28000000 128M Reserved for shared libraries.
23 * 0x28000000->0x38000000 256M Static Space.
24 * 0x38000000->0x40000000 128M Binding stack growing up.
25 * 0x40000000->0x48000000 128M Control stack growing down.
26 * 0x48000000->0xB0000000 1664M Dynamic Space.
27 * 0xB0000000->0xB1000000 Foreign Linkage Table
28 * 0xE0000000-> 256M C stack - Alien stack.
29 *
30 * OpenBSD:
31 * 0x00000000->0x0E000000 224M C program and memory allocation.
32 * 0x0E000000->0x10000000 32M Foreign segment.
33 * 0x10000000->0x20000000 256M Read-Only Space.
34 * 0x20000000->0x28000000 128M Binding stack growing up.
35 * 0x28000000->0x38000000 256M Static Space.
36 * 0x38000000->0x40000000 128M Control stack growing down.
37 * 0x40000000->0x48000000 128M Reserved for shared libraries.
38 * 0x48000000->0xB0000000 1664M Dynamic Space.
39 * 0xB0000000->0xB1000000 16M Foreign Linkage Table
40 * 0xE0000000-> 256M C stack - Alien stack.
41 *
42 * NetBSD:
43 * 0x00000000->0x0E000000 224M C program and memory allocation.
44 * 0x0E000000->0x10000000 32M Foreign segment.
45 * 0x10000000->0x20000000 256M Read-Only Space.
46 * 0x28000000->0x38000000 256M Static Space.
47 * 0x38000000->0x40000000 128M Binding stack growing up.
48 * 0x40000000->0x48000000 128M Control stack growing down.
49 * 0x48800000->0xB0000000 1656M Dynamic Space.
50 * 0xB0000000->0xB1000000 16M Foreign Linkage Table
51 * 0xE0000000-> 256M C stack - Alien stack.
52 *
53 * Linux:
54 * 0x00000000->0x08000000 128M Unused.
55 * 0x08000000->0x10000000 128M C program and memory allocation.
56 * 0x10000000->0x20000000 256M Read-Only Space.
57 * 0x20000000->0x28000000 128M Binding stack growing up.
58 * 0x28000000->0x38000000 256M Static Space.
59 * 0x38000000->0x40000000 128M Control stack growing down.
60 * 0x40000000->0x48000000 128M Reserved for shared libraries.
61 * 0x58000000->0x58100000 16M Foreign Linkage Table
62 * 0x58100000->0xBE000000 1631M Dynamic Space.
63 * 0xBFFF0000->0xC0000000 Unknown Linux mapping
64 *
65 * (Note: 0x58000000 allows us to run on a Linux system on an AMD
66 * x86-64. Hence we have a gap of unused memory starting at
67 * 0x48000000.)
68 */
69
70 #ifdef __FreeBSD__
71 #define READ_ONLY_SPACE_START (0x10000000)
72 #define READ_ONLY_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
73
74 #define STATIC_SPACE_START (0x28f00000)
75 #define STATIC_SPACE_SIZE (0x0f0ff000) /* 241MB - 1 page */
76
77 #define BINDING_STACK_START (0x38000000)
78 #define BINDING_STACK_SIZE (0x07fff000) /* 128MB - 1 page */
79
80 #define CONTROL_STACK_START 0x40000000
81 #define CONTROL_STACK_SIZE 0x07fd8000 /* 128MB - SIGSTKSZ */
82 #define SIGNAL_STACK_START 0x47fd8000
83 #define SIGNAL_STACK_SIZE SIGSTKSZ
84
85 #define DYNAMIC_0_SPACE_START (0x48000000)
86 #ifdef GENCGC
87 #define DYNAMIC_SPACE_SIZE (0x78000000) /* May be up to 1.7 GB */
88 #else
89 #define DYNAMIC_SPACE_SIZE (0x04000000) /* 64MB */
90 #endif
91 #define DEFAULT_DYNAMIC_SPACE_SIZE (0x20000000) /* 512MB */
92 #ifdef LINKAGE_TABLE
93 #define FOREIGN_LINKAGE_SPACE_START ((unsigned long) LinkageSpaceStart)
94 #define FOREIGN_LINKAGE_SPACE_SIZE (0x100000) /* 1MB */
95 #endif
96 #endif /* __FreeBSD__ */
97
98
99 #ifdef __OpenBSD__
100 #define READ_ONLY_SPACE_START (0x10000000)
101 #define READ_ONLY_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
102
103 #define STATIC_SPACE_START (0x28000000)
104 #define STATIC_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
105
106 #define BINDING_STACK_START (0x38000000)
107 #define BINDING_STACK_SIZE (0x07fff000) /* 128MB - 1 page */
108
109 #define CONTROL_STACK_START (0x40000000)
110 #define CONTROL_STACK_SIZE (0x07fd8000) /* 128MB - SIGSTKSZ */
111
112 #define SIGNAL_STACK_START (0x47fd8000)
113 #define SIGNAL_STACK_SIZE SIGSTKSZ
114
115 #define DYNAMIC_0_SPACE_START (0x48000000)
116 #ifdef GENCGC
117 #define DYNAMIC_SPACE_SIZE (0x68000000) /* 1.625GB */
118 #else
119 #define DYNAMIC_SPACE_SIZE (0x04000000) /* 64MB */
120 #endif
121 #define DEFAULT_DYNAMIC_SPACE_SIZE (0x20000000) /* 512MB */
122 #endif
123
124 #if defined(__NetBSD__) || defined(DARWIN)
125 #define READ_ONLY_SPACE_START (0x10000000)
126 #define READ_ONLY_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
127
128 #define STATIC_SPACE_START (0x28000000)
129 #define STATIC_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
130
131 #define BINDING_STACK_START (0x38000000)
132 #define BINDING_STACK_SIZE (0x07fff000) /* 128MB - 1 page */
133
134 #define CONTROL_STACK_START (0x40000000)
135 #define CONTROL_STACK_SIZE (0x07fd8000) /* 128MB - SIGSTKSZ */
136
137 #define SIGNAL_STACK_START (0x47fd8000)
138 #define SIGNAL_STACK_SIZE SIGSTKSZ
139
140 #define DYNAMIC_0_SPACE_START (0x48000000)
141 #ifdef GENCGC
142 #define DYNAMIC_SPACE_SIZE (0x67800000) /* 1.656GB */
143 #else
144 #define DYNAMIC_SPACE_SIZE (0x04000000) /* 64MB */
145 #endif
146 #define DEFAULT_DYNAMIC_SPACE_SIZE (0x20000000) /* 512MB */
147 #ifdef LINKAGE_TABLE
148 #define FOREIGN_LINKAGE_SPACE_START (0xb0000000)
149 #define FOREIGN_LINKAGE_SPACE_SIZE (0x100000) /* 1MB */
150 #endif
151 #endif /* __NetBSD__ || DARWIN */
152
153 #ifdef __linux__
154 #define READ_ONLY_SPACE_START (SpaceStart_TargetReadOnly)
155 #define READ_ONLY_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
156
157 #define STATIC_SPACE_START (SpaceStart_TargetStatic)
158 #define STATIC_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
159
160 #define BINDING_STACK_START (0x20000000)
161 #define BINDING_STACK_SIZE (0x07fff000) /* 128MB - 1 page */
162
163 #define CONTROL_STACK_START 0x38000000
164 #define CONTROL_STACK_SIZE (0x07fff000 - 8192)
165 #define SIGNAL_STACK_START CONTROL_STACK_END
166 #define SIGNAL_STACK_SIZE 8192
167
168 #define DYNAMIC_0_SPACE_START (SpaceStart_TargetDynamic)
169
170 #ifdef GENCGC
171 #define DYNAMIC_SPACE_SIZE (0x66000000) /* 1.632GB */
172 #else
173 #define DYNAMIC_SPACE_SIZE (0x04000000) /* 64MB */
174 #endif
175 #define DEFAULT_DYNAMIC_SPACE_SIZE (0x20000000) /* 512MB */
176 #ifdef LINKAGE_TABLE
177 #define FOREIGN_LINKAGE_SPACE_START (LinkageSpaceStart)
178 #define FOREIGN_LINKAGE_SPACE_SIZE (0x100000) /* 1MB */
179 #endif
180 #endif
181
182
183 #define CONTROL_STACK_END (CONTROL_STACK_START + CONTROL_STACK_SIZE)
184
185 /* Note that GENCGC only uses dynamic_space 0. */
186 #define DYNAMIC_1_SPACE_START (DYNAMIC_0_SPACE_START + DYNAMIC_SPACE_SIZE)
187
188 #endif /* _X86_VALIDATE_H_ */

  ViewVC Help
Powered by ViewVC 1.1.5