diff --git a/gc.c b/gc.c index 38dcde1a..bdce29ae 100644 --- a/gc.c +++ b/gc.c @@ -932,6 +932,9 @@ void gc_collector_trace() while (m->last_read < m->last_write) { clean = 0; (m->last_read)++; +printf("gc_mark_black mark buffer %p, last_read = %d last_write = %d\n", +(m->mark_buffer)[m->last_read], +m->last_read, m->last_write); gc_mark_black((m->mark_buffer)[m->last_read]); gc_empty_collector_stack(); } @@ -1006,6 +1009,9 @@ void gc_mark_black(object obj) mark(obj) = markColor; printf("marked %p %d\n", obj, markColor); } + else { + printf("not marking stack obj %p %d\n", obj, markColor); + } } } diff --git a/runtime.c b/runtime.c index 9114ec66..69b9904d 100644 --- a/runtime.c +++ b/runtime.c @@ -2441,7 +2441,7 @@ void gc_mark_globals() printf("(gc_mark_globals heap: %p size: %d)\n", h, (unsigned int)gc_heap_total_size(h)); #endif // Mark global variables -printf("Cyc_global_variables %p\n"); +printf("Cyc_global_variables %p\n", Cyc_global_variables); gc_mark_black(Cyc_global_variables); // Internal global used by the runtime // Marking it ensures all glos are marked {