/[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.16.4.1 - (show annotations)
Sun Mar 9 12:51:57 2003 UTC (11 years, 1 month ago) by gerd
Branch: cold-pcl
Changes since 1.16: +9 -5 lines
File MIME type: text/plain
*** empty log message ***
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.16.4.1 2003/03/09 12:51:57 gerd Exp $
7 *
8 */
9
10 /*
11 * Address map:
12 *
13 * FreeBSD:
14 * 0x00000000->0x0E000000 224M C program and memory allocation.
15 * 0x0E000000->0x10000000 32M Foreign segment.
16 * 0x10000000->0x20000000 256M Read-Only Space.
17 * 0x20000000->0x28000000 128M Reserved for shared libraries.
18 * 0x28000000->0x38000000 256M Static Space.
19 * 0x38000000->0x40000000 128M Binding stack growing up.
20 * 0x40000000->0x48000000 128M Control stack growing down.
21 * 0x48000000->0xC8000000 2GB Dynamic Space.
22 * 0xE0000000-> 256M C stack - Alien stack.
23 *
24 * OpenBSD and NetBSD:
25 * 0x00000000->0x0E000000 224M C program and memory allocation.
26 * 0x0E000000->0x10000000 32M Foreign segment.
27 * 0x10000000->0x20000000 256M Read-Only Space.
28 * 0x20000000->0x28000000 128M Binding stack growing up.
29 * 0x28000000->0x38000000 256M Static Space.
30 * 0x38000000->0x40000000 128M Control stack growing down.
31 * 0x40000000->0x48000000 128M Reserved for shared libraries.
32 * 0x48000000->0xB8000000 1.75GB Dynamic Space.
33 * 0xE0000000-> 256M C stack - Alien stack.
34 *
35 * Linux:
36 * 0x00000000->0x08000000 128M Unused.
37 * 0x08000000->0x10000000 128M C program and memory allocation.
38 * 0x10000000->0x20000000 256M Read-Only Space.
39 * 0x20000000->0x28000000 128M Binding stack growing up.
40 * 0x28000000->0x38000000 256M Static Space.
41 * 0x38000000->0x40000000 128M Control stack growing down.
42 * 0x40000000->0x48000000 128M Reserved for shared libraries.
43 * 0x48000000->0xB8000000 1.75G Dynamic Space.
44 *
45 */
46
47 #ifdef __FreeBSD__
48 #define READ_ONLY_SPACE_START (0x10000000)
49 #define READ_ONLY_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
50
51 #define STATIC_SPACE_START (0x28f00000)
52 #define STATIC_SPACE_SIZE (0x0f0ff000) /* 241MB - 1 page */
53
54 #define BINDING_STACK_START (0x38000000)
55 #define BINDING_STACK_SIZE (0x07fff000) /* 128MB - 1 page */
56
57 #define CONTROL_STACK_START 0x40000000
58 #define CONTROL_STACK_SIZE 0x07fd8000 /* 128MB - SIGSTKSZ */
59 #define SIGNAL_STACK_START 0x47fd8000
60 #define SIGNAL_STACK_SIZE SIGSTKSZ
61
62 #define DYNAMIC_0_SPACE_START (0x48000000)
63 #ifdef GENCGC
64 #define DYNAMIC_SPACE_SIZE (0x40000000) /* May be up to 2GB */
65 #else
66 #define DYNAMIC_SPACE_SIZE (0x04000000) /* 64MB */
67 #endif
68 #define DEFAULT_DYNAMIC_SPACE_SIZE (0x20000000) /* 512MB */
69 #ifdef LINKAGE_TABLE
70 #define FOREIGN_LINKAGE_SPACE_START (0xb0000000)
71 #define FOREIGN_LINKAGE_SPACE_SIZE (0x100000) /* 1MB */
72 #endif
73 #endif /* __FreeBSD__ */
74
75
76 #if defined(__OpenBSD__) || defined(__NetBSD__)
77 #define READ_ONLY_SPACE_START (0x10000000)
78 #define READ_ONLY_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
79
80 #define STATIC_SPACE_START (0x28000000)
81 #define STATIC_SPACE_SIZE (0x0ffff000) /* 256MB - 1 page */
82
83 #define BINDING_STACK_START (0x20000000)
84 #define BINDING_STACK_SIZE (0x07fff000) /* 128MB - 1 page */
85
86 #define CONTROL_STACK_START (0x38000000)
87 #define CONTROL_STACK_SIZE (0x07fff000) /* 128MB - 1 page */
88
89 #define DYNAMIC_0_SPACE_START (0x48000000)
90 #ifdef GENCGC
91 #define DYNAMIC_SPACE_SIZE (0x68000000) /* 1.625GB */
92 #else
93 #define DYNAMIC_SPACE_SIZE (0x04000000) /* 64MB */
94 #endif
95 #define DEFAULT_DYNAMIC_SPACE_SIZE (0x20000000) /* 512MB */
96 #endif
97
98
99 #ifdef __linux__
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 (0x20000000)
107 #define BINDING_STACK_SIZE (0x07fff000) /* 128MB - 1 page */
108
109 #define CONTROL_STACK_START 0x38000000
110 #define CONTROL_STACK_SIZE (0x07fff000 - 8192)
111 #define SIGNAL_STACK_START CONTROL_STACK_END
112 #define SIGNAL_STACK_SIZE 8192
113
114 #define DYNAMIC_0_SPACE_START (0x48000000)
115 #ifdef GENCGC
116 #define DYNAMIC_SPACE_SIZE (0x68000000) /* 1.625GB */
117 #else
118 #define DYNAMIC_SPACE_SIZE (0x04000000) /* 64MB */
119 #endif
120 #define DEFAULT_DYNAMIC_SPACE_SIZE (0x20000000) /* 512MB */
121 #ifdef LINKAGE_TABLE
122 #define FOREIGN_LINKAGE_SPACE_START (0xb0000000)
123 #define FOREIGN_LINKAGE_SPACE_SIZE (0x100000) /* 1MB */
124 #endif
125 #endif
126
127
128 #define CONTROL_STACK_END (CONTROL_STACK_START + CONTROL_STACK_SIZE)
129
130 /* Note that GENCGC only uses dynamic_space 0. */
131 #define DYNAMIC_1_SPACE_START (DYNAMIC_0_SPACE_START + DYNAMIC_SPACE_SIZE)

  ViewVC Help
Powered by ViewVC 1.1.5