X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fruntime%2Fcoreparse.c;h=d1b8b96f5060fe6c71209db38a91d37b5a8abed1;hb=71c5af561afd99e3bfe4cb76f492567b50893569;hp=bc562ba63effc357342fabdce4eb6685039b1fdd;hpb=77bb7c43dae7507aacae795af427548cb4616bc8;p=sbcl.git diff --git a/src/runtime/coreparse.c b/src/runtime/coreparse.c index bc562ba..d1b8b96 100644 --- a/src/runtime/coreparse.c +++ b/src/runtime/coreparse.c @@ -22,13 +22,17 @@ #include #include #include + +#include "sbcl.h" + +#ifndef LISP_FEATURE_WIN32 #ifdef LISP_FEATURE_LINUX /* For madvise */ # define _BSD_SOURCE #endif #include +#endif -#include "sbcl.h" #include "os.h" #include "runtime.h" #include "globals.h" @@ -40,12 +44,6 @@ #include "validate.h" #include "gc-internal.h" -/* lutex stuff */ -#if defined(LISP_FEATURE_SB_THREAD) && defined(LISP_FEATURE_SB_LUTEX) -#include "genesis/sap.h" -#include "pthread-lutex.h" -#endif - #include #ifdef LISP_FEATURE_SB_CORE_COMPRESSION @@ -100,7 +98,7 @@ maybe_initialize_runtime_options(int fd) lseek(fd, -end_offset, SEEK_END); - if (new_runtime_options = read_runtime_options(fd)) { + if ((new_runtime_options = read_runtime_options(fd))) { runtime_options = new_runtime_options; } } @@ -486,41 +484,6 @@ load_core_file(char *file, os_vm_offset_t file_offset) initial_function = (lispobj)*ptr; break; -#if defined(LISP_FEATURE_SB_THREAD) && defined(LISP_FEATURE_SB_LUTEX) - case LUTEX_TABLE_CORE_ENTRY_TYPE_CODE: - SHOW("LUTEX_TABLE_CORE_ENTRY_TYPE_CODE case"); - { - size_t n_lutexes = *ptr; - size_t fdoffset = (*(ptr + 1) + 1) * (os_vm_page_size); - size_t data_length = n_lutexes * sizeof(struct sap *); - struct lutex **lutexes_to_resurrect = malloc(data_length); - long bytes_read; - - lseek(fd, fdoffset + file_offset, SEEK_SET); - - FSHOW((stderr, "attempting to read %ld lutexes from core\n", n_lutexes)); - bytes_read = read(fd, lutexes_to_resurrect, data_length); - - /* XXX */ - if (bytes_read != data_length) { - lose("Could not read the lutex table"); - } - else { - int i; - - for (i=0; i