Places start_module and atomic mark traversal fixes
svn: r15958
This commit is contained in:
parent
f49af7c4fa
commit
0d1409e5fd
|
@ -338,7 +338,14 @@ inline static void mark_normal_obj(NewGC *gc, int type, void *ptr)
|
||||||
ignore them outright. In the case of custodians, we do need
|
ignore them outright. In the case of custodians, we do need
|
||||||
to do the check; those differences are handled by replacing
|
to do the check; those differences are handled by replacing
|
||||||
the mark procedure in mark_table. */
|
the mark procedure in mark_table. */
|
||||||
gc->mark_table[*(unsigned short*)ptr](ptr);
|
unsigned short tag = *(unsigned short*)ptr;
|
||||||
|
ASSERT_TAG(tag);
|
||||||
|
if((unsigned long)gc->mark_table[tag] < PAGE_TYPES) {
|
||||||
|
/* atomic */
|
||||||
|
} else {
|
||||||
|
GC_ASSERT(mark_table[tag]);
|
||||||
|
gc->mark_table[tag](ptr);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case PAGE_ATOMIC: break;
|
case PAGE_ATOMIC: break;
|
||||||
|
@ -403,6 +410,12 @@ static void propagate_accounting_marks(NewGC *gc)
|
||||||
PageMap pagemap = gc->page_maps;
|
PageMap pagemap = gc->page_maps;
|
||||||
while(pop_ptr(&p) && !gc->kill_propagation_loop) {
|
while(pop_ptr(&p) && !gc->kill_propagation_loop) {
|
||||||
page = pagemap_find_page(pagemap, p);
|
page = pagemap_find_page(pagemap, p);
|
||||||
|
#ifdef MZ_USE_PLACES
|
||||||
|
if (!page) {
|
||||||
|
page = pagemap_find_page(MASTERGC->page_maps, p);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
GC_ASSERT(page);
|
||||||
set_backtrace_source(p, page->page_type);
|
set_backtrace_source(p, page->page_type);
|
||||||
GCDEBUG((DEBUGOUTF, "btc_account: popped off page %p:%p, ptr %p\n", page, page->addr, p));
|
GCDEBUG((DEBUGOUTF, "btc_account: popped off page %p:%p, ptr %p\n", page, page->addr, p));
|
||||||
if(page->size_class) {
|
if(page->size_class) {
|
||||||
|
|
|
@ -1483,7 +1483,7 @@ inline static void mark_stack_initialize() {
|
||||||
|
|
||||||
inline static void push_ptr(void *ptr)
|
inline static void push_ptr(void *ptr)
|
||||||
{
|
{
|
||||||
/* This happens during propoagation if we go past the end of this MarkSegment*/
|
/* This happens during propagation if we go past the end of this MarkSegment*/
|
||||||
if(mark_stack->top == MARK_STACK_END(mark_stack)) {
|
if(mark_stack->top == MARK_STACK_END(mark_stack)) {
|
||||||
/* test to see if we already have another stack page ready */
|
/* test to see if we already have another stack page ready */
|
||||||
if(mark_stack->next) {
|
if(mark_stack->next) {
|
||||||
|
|
|
@ -4071,7 +4071,7 @@ static void start_module(Scheme_Module *m, Scheme_Env *env, int restart,
|
||||||
Scheme_Object *l, *new_cycle_list;
|
Scheme_Object *l, *new_cycle_list;
|
||||||
int prep_namespace = 0;
|
int prep_namespace = 0;
|
||||||
|
|
||||||
if (SAME_OBJ(m, kernel))
|
if (is_builtin_modname(m->modname))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
for (l = cycle_list; !SCHEME_NULLP(l); l = SCHEME_CDR(l)) {
|
for (l = cycle_list; !SCHEME_NULLP(l); l = SCHEME_CDR(l)) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user