Merge PPC port
[sbcl/lichteblau.git] / src / runtime / globals.h
blob495e8552083fd8593a1d399a9e7bde387e0bdc22
1 /*
2 * This software is part of the SBCL system. See the README file for
3 * more information.
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 "runtime.h"
19 extern int foreign_function_call_active;
21 extern lispobj *current_control_stack_pointer;
22 extern lispobj *current_control_frame_pointer;
23 #if !defined(__i386__)
24 extern lispobj *current_binding_stack_pointer;
25 #endif
27 #if !defined(__i386__)
28 /* FIXME: Why doesn't the x86 need this? */
29 extern lispobj *dynamic_space_free_pointer;
30 extern lispobj *current_auto_gc_trigger;
31 #endif
33 extern lispobj *current_dynamic_space;
35 extern void globals_init(void);
37 #else LANGUAGE_ASSEMBLY
39 #ifdef mips
40 #define EXTERN(name,bytes) .extern name bytes
41 #endif
42 /**/
43 #ifdef sparc
44 #ifdef SVR4
45 #define EXTERN(name,bytes) .global name
46 #else
47 #define EXTERN(name,bytes) .global _ ## name
48 #endif
49 #endif
50 /**/
51 #ifdef alpha
52 #ifdef __linux__
53 #define EXTERN(name,bytes) .globl name
54 #endif
55 #endif
56 #ifdef ppc
57 #define EXTERN(name,bytes) .globl name
58 #endif
59 #ifdef __i386__
60 #ifdef __linux__
61 /* I'm very dubious about this. Linux hasn't used _ on external names
62 * since ELF became prevalent - i.e. about 1996, on x86 -dan 20010125 */
63 #define EXTERN(name,bytes) .globl _/**/name
64 #else
65 #define EXTERN(name,bytes) .global _ ## name
66 #endif
67 #endif
69 EXTERN(foreign_function_call_active, 4)
71 EXTERN(current_control_stack_pointer, 4)
72 EXTERN(current_control_frame_pointer, 4)
73 EXTERN(current_binding_stack_pointer, 4)
74 EXTERN(dynamic_space_free_pointer, 4)
75 EXTERN(current_dynamic_space, 4)
77 #ifdef mips
78 EXTERN(current_flags_register, 4)
79 #endif
81 #endif LANGUAGE_ASSEMBLY
83 #endif _INCLUDED_GLOBALS_H_