2 * This software is part of the SBCL system. See the README file for
5 * This software is derived from the CMU CL system, which was
6 * written at Carnegie Mellon University and released into the
7 * public domain. The software is in the public domain and is
8 * provided with absolutely no warranty. See the COPYING and CREDITS
9 * files for more information.
12 #if !defined(_INCLUDE_GLOBALS_H_)
13 #define _INCLUDED_GLOBALS_H_
15 #ifndef LANGUAGE_ASSEMBLY
17 #include <sys/types.h>
22 extern int foreign_function_call_active;
23 extern boolean stop_the_world;
25 extern lispobj *current_control_stack_pointer;
26 extern lispobj *current_control_frame_pointer;
27 #if !defined(LISP_FEATURE_X86)
28 extern lispobj *current_binding_stack_pointer;
31 #if !defined(LISP_FEATURE_X86)
32 /* FIXME: Why doesn't the x86 need this? */
33 extern lispobj *dynamic_space_free_pointer;
34 extern lispobj *current_auto_gc_trigger;
37 extern lispobj *current_dynamic_space;
38 extern pid_t parent_pid;
39 extern boolean stop_the_world;
41 extern void globals_init(void);
43 #else /* LANGUAGE_ASSEMBLY */
46 #define EXTERN(name,bytes) .extern name bytes
51 #define EXTERN(name,bytes) .global name
53 #define EXTERN(name,bytes) .global _ ## name
59 #define EXTERN(name,bytes) .globl name
63 #ifdef LISP_FEATURE_DARWIN
64 #define EXTERN(name,bytes) .globl _/**/name
66 #define EXTERN(name,bytes) .globl name
69 #ifdef LISP_FEATURE_X86
71 /* I'm very dubious about this. Linux hasn't used _ on external names
72 * since ELF became prevalent - i.e. about 1996, on x86 -dan 20010125 */
73 #define EXTERN(name,bytes) .globl _/**/name
75 #define EXTERN(name,bytes) .global _ ## name
79 /* FIXME : these sizes are, incidentally, bogus on Alpha. But the
80 * EXTERN macro doesn't use its second arg anyway, so no immediate harm
81 * done -dan 2002.05.07
84 EXTERN(foreign_function_call_active, 4)
86 EXTERN(current_control_stack_pointer, 4)
87 EXTERN(current_control_frame_pointer, 4)
88 EXTERN(current_binding_stack_pointer, 4)
89 EXTERN(dynamic_space_free_pointer, 4)
90 EXTERN(current_dynamic_space, 4)
93 EXTERN(current_flags_register, 4)
96 #endif /* LANGUAGE_ASSEMBLY */
98 #endif /* _INCLUDED_GLOBALS_H_ */