From 723a6ed37175fcade87802c8ab44325971446020 Mon Sep 17 00:00:00 2001 From: Paul Sokolovsky Date: Tue, 11 Feb 2014 18:01:38 +0200 Subject: More GC debugging improvements. --- unix/gccollect.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'unix') diff --git a/unix/gccollect.c b/unix/gccollect.c index cb2cc7a03..60bc99323 100644 --- a/unix/gccollect.c +++ b/unix/gccollect.c @@ -48,6 +48,8 @@ void gc_helper_get_regs(regs_t arr) { #endif void gc_collect(void) { + //gc_dump_info(); + gc_collect_start(); // this traces .data and .bss sections extern char __bss_start, _end; @@ -59,14 +61,8 @@ void gc_collect(void) { gc_collect_root((void**)®s, ((uint32_t)stack_top - (uint32_t)®s) / sizeof(uint32_t)); gc_collect_end(); - if (0) { - // print GC info - gc_info_t info; - gc_info(&info); - printf("GC: total: " UINT_FMT ", used: " UINT_FMT ", free: " UINT_FMT "\n", info.total, info.used, info.free); - printf(" No. of 1-blocks: " UINT_FMT ", 2-blocks: " UINT_FMT ", max blk sz: " UINT_FMT "\n", - info.num_1block, info.num_2block, info.max_block); - } + //printf("-----\n"); + //gc_dump_info(); } #endif //MICROPY_ENABLE_GC -- cgit v1.2.3