Skip to content

Commit 68a7a92

Browse files
committed
py/gc: gc_dump_alloc_table(): Dump heap offset instead of actual address.
Address printed was truncated anyway and in general confusing to outsider. A line which dumps it is still left in the source, commented, for peculiar cases when it may be needed (e.g. when running under debugger).
1 parent 9a8751b commit 68a7a92

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

py/gc.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -693,11 +693,8 @@ void gc_dump_alloc_table(void) {
693693
}
694694
// print header for new line of blocks
695695
// (the cast to uint32_t is for 16-bit ports)
696-
#if EXTENSIVE_HEAP_PROFILING
696+
//mp_printf(&mp_plat_print, "\n%05x: ", (uint)(PTR_FROM_BLOCK(bl) & (uint32_t)0xfffff));
697697
mp_printf(&mp_plat_print, "\n%05x: ", (uint)((bl * BYTES_PER_BLOCK) & (uint32_t)0xfffff));
698-
#else
699-
mp_printf(&mp_plat_print, "\n%05x: ", (uint)(PTR_FROM_BLOCK(bl) & (uint32_t)0xfffff));
700-
#endif
701698
}
702699
int c = ' ';
703700
switch (ATB_GET_KIND(bl)) {

0 commit comments

Comments
 (0)