diff options
Diffstat (limited to 'py/gc.c')
-rw-r--r-- | py/gc.c | 14 |
1 files changed, 9 insertions, 5 deletions
@@ -693,11 +693,8 @@ void gc_dump_alloc_table(void) { } // print header for new line of blocks // (the cast to uint32_t is for 16-bit ports) - #if EXTENSIVE_HEAP_PROFILING + //mp_printf(&mp_plat_print, "\n%05x: ", (uint)(PTR_FROM_BLOCK(bl) & (uint32_t)0xfffff)); mp_printf(&mp_plat_print, "\n%05x: ", (uint)((bl * BYTES_PER_BLOCK) & (uint32_t)0xfffff)); - #else - mp_printf(&mp_plat_print, "\n%05x: ", (uint)(PTR_FROM_BLOCK(bl) & (uint32_t)0xfffff)); - #endif } int c = ' '; switch (ATB_GET_KIND(bl)) { @@ -734,6 +731,13 @@ void gc_dump_alloc_table(void) { if (*ptr == &mp_type_tuple) { c = 'T'; } else if (*ptr == &mp_type_list) { c = 'L'; } else if (*ptr == &mp_type_dict) { c = 'D'; } + else if (*ptr == &mp_type_str || *ptr == &mp_type_bytes) { c = 'S'; } + #if MICROPY_PY_BUILTINS_BYTEARRAY + else if (*ptr == &mp_type_bytearray) { c = 'A'; } + #endif + #if MICROPY_PY_ARRAY + else if (*ptr == &mp_type_array) { c = 'A'; } + #endif #if MICROPY_PY_BUILTINS_FLOAT else if (*ptr == &mp_type_float) { c = 'F'; } #endif @@ -761,7 +765,7 @@ void gc_dump_alloc_table(void) { } break; } - case AT_TAIL: c = 't'; break; + case AT_TAIL: c = '='; break; case AT_MARK: c = 'm'; break; } mp_printf(&mp_plat_print, "%c", c); |