X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fruntime%2Fpurify.c;h=e93e170fbc11c72ae99f6f7bb07cee10a38ec81b;hb=b3a419f10ad442a1c59d51edabdc70518f193648;hp=45a0e6d5d9f4f83cbbdea0102e4b3a3f695c50a5;hpb=9f10bc102adce15a820027777a03e49a7b7623da;p=sbcl.git diff --git a/src/runtime/purify.c b/src/runtime/purify.c index 45a0e6d..e93e170 100644 --- a/src/runtime/purify.c +++ b/src/runtime/purify.c @@ -28,6 +28,8 @@ #include "interr.h" #include "gc.h" #include "gc-internal.h" +#include "genesis/primitive-objects.h" +#include "genesis/static-symbols.h" #define PRINTNOISE @@ -362,6 +364,11 @@ setup_i386_stack_scav(lispobj *lowaddr, lispobj *base) * return addresses. This will also pick up pointers to * functions in code objects. */ if (widetag_of(*start_addr) == CODE_HEADER_WIDETAG) { + /* FIXME asserting here is a really dumb thing to do. + * If we've overflowed some arbitrary static limit, we + * should just refuse to purify, instead of killing + * the whole lisp session + */ gc_assert(num_valid_stack_ra_locations < MAX_STACK_RETURN_ADDRESSES); valid_stack_ra_locations[num_valid_stack_ra_locations] = sp; @@ -1295,11 +1302,14 @@ purify(lispobj static_roots, lispobj read_only_roots) int count, i; struct later *laters, *next; + #ifdef PRINTNOISE printf("[doing purification:"); fflush(stdout); #endif - +#ifdef LISP_FEATURE_GENCGC + gc_alloc_update_all_page_tables(); +#endif if (fixnum_value(SymbolValue(FREE_INTERRUPT_CONTEXT_INDEX)) != 0) { /* FIXME: 1. What does this mean? 2. It shouldn't be reporting * its error simply by a. printing a string b. to stdout instead @@ -1324,7 +1334,7 @@ purify(lispobj static_roots, lispobj read_only_roots) fflush(stdout); #endif -#ifdef LISP_FEATURE_GENCGC +#if (defined(LISP_FEATURE_GENCGC) && defined(LISP_FEATURE_X86)) gc_assert((lispobj *)CONTROL_STACK_END > ((&read_only_roots)+1)); setup_i386_stack_scav(((&static_roots)-2), (lispobj *)CONTROL_STACK_END); #endif