Clean up RCS ids
[projects/cmucl/cmucl.git] / src / lisp / globals.c
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 */
7 /* Variables everybody needs to look at or frob on. */
8
9 #include <stdio.h>
10
11 #include "lisp.h"
12 #include "internals.h"
13 #include "globals.h"
14
15 int foreign_function_call_active;
16
17 lispobj *current_control_stack_pointer;
18 lispobj *current_control_frame_pointer;
19
20 #ifndef BINDING_STACK_POINTER
21 lispobj *current_binding_stack_pointer;
22 #endif
23
24 lispobj *read_only_space;
25 lispobj *static_space;
26 lispobj *dynamic_0_space;
27 lispobj *dynamic_1_space;
28 unsigned dynamic_space_size;
29 lispobj *control_stack;
30
31
32 #if (defined(i386) || defined(__x86_64))
33 lispobj *control_stack_end;
34 #endif
35 lispobj *binding_stack;
36
37 lispobj *current_dynamic_space;
38
39 #ifndef ALLOCATION_POINTER
40 lispobj *current_dynamic_space_free_pointer;
41 #endif
42 #ifndef INTERNAL_GC_TRIGGER
43 lispobj *current_auto_gc_trigger;
44 #endif
45
46 unsigned long read_only_space_size;
47 unsigned long binding_stack_size;
48 unsigned long static_space_size;
49 unsigned long control_stack_size;
50
51
52 void
53 globals_init(void)
54 {
55     /* Space, stack, and free pointer vars are initialized by
56        validate() and coreparse(). */
57
58 #ifndef INTERNAL_GC_TRIGGER
59     /* No GC trigger yet */
60     current_auto_gc_trigger = NULL;
61 #endif
62
63     /* Set foreign function call active. */
64     foreign_function_call_active = 1;
65
66     /* Initialize the current lisp state. */
67 #if !(defined(i386) || defined(__x86_64))
68     current_control_stack_pointer = control_stack;
69 #else
70     current_control_stack_pointer = control_stack_end;
71 #endif
72
73     current_control_frame_pointer = (lispobj *) 0;
74 #ifndef BINDING_STACK_POINTER
75     current_binding_stack_pointer = binding_stack;
76 #endif
77 }