Skip to content
Snippets Groups Projects
Commit 68a7a92c authored by Paul Sokolovsky's avatar Paul Sokolovsky
Browse files

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).
parent 9a8751b0
No related branches found
No related tags found
No related merge requests found
......@@ -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)) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment