Try to make the :lurking-threads test more robust.
[sbcl.git] / src / runtime / core.h
blob43f24550b4b3652788c4c2d24fabd88da8b397fe
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 #ifndef _CORE_H_
13 #define _CORE_H_
15 #include "sbcl.h"
16 #include "runtime.h"
18 #ifdef LISP_FEATURE_ALPHA
19 typedef u32 core_entry_elt_t;
20 #else
21 typedef sword_t core_entry_elt_t;
22 #endif
24 struct ndir_entry {
25 core_entry_elt_t identifier;
26 core_entry_elt_t nwords;
27 core_entry_elt_t data_page;
28 core_entry_elt_t address;
29 core_entry_elt_t page_count;
31 #define NDIR_ENTRY_LENGTH (sizeof (struct ndir_entry)/sizeof (core_entry_elt_t))
33 #define RUNTIME_OPTIONS_MAGIC 0x31EBF355
34 /* 1 for magic, 1 for core entry size in words, 2 for struct runtime_options fields */
35 #define RUNTIME_OPTIONS_WORDS (1 + 1 + 2)
37 struct memsize_options {
38 os_vm_size_t dynamic_space_size;
39 os_vm_size_t thread_control_stack_size;
40 int present_in_core;
43 extern lispobj load_core_file(char *file, os_vm_offset_t file_offset,
44 int merge_core_pages);
45 extern os_vm_offset_t search_for_embedded_core(char *filename,
46 struct memsize_options *memsize_options);
48 /* arbitrary string identifying this build, embedded in .core files to
49 * prevent people mismatching a runtime built e.g. with :SB-SHOW
50 * against a .core built without :SB-SHOW (or against various grosser
51 * mismatches, e.g. a .core built with an old version of the code
52 * against a runtime with patches which add new C code) */
53 extern unsigned char build_id[];
55 #endif