summaryrefslogtreecommitdiff
path: root/mark_rts.c
diff options
context:
space:
mode:
authorIvan Maidanski <ivmai@mail.ru>2013-06-12 09:50:04 +0400
committerIvan Maidanski <ivmai@mail.ru>2013-06-12 12:50:55 +0400
commitca89b8c4820836daecb2b1ab4431808721d33f1f (patch)
tree0a60424e4b5484f2c11ef7938ad3f20a51097377 /mark_rts.c
parente1243339b15b8dea971bce51d1362ee8024771ee (diff)
downloadbdwgc-ca89b8c4820836daecb2b1ab4431808721d33f1f.tar.gz
Improve debug-only messages of add/remove_roots and init_linux_data_start
* mark_rts.c (GC_add_roots_inner, GC_remove_root_at_pos): Log r_tmp value (only if DEBUG_ADD_DEL_ROOTS). * os_dep.c (GC_init_linux_data_start): Log unresolved [__]data_start symbol (only if DEBUG_ADD_DEL_ROOTS and LINUX).
Diffstat (limited to 'mark_rts.c')
-rw-r--r--mark_rts.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/mark_rts.c b/mark_rts.c
index 7ffe82a6..a8dc04a2 100644
--- a/mark_rts.c
+++ b/mark_rts.c
@@ -246,8 +246,8 @@ void GC_add_roots_inner(ptr_t b, ptr_t e, GC_bool tmp)
}
# ifdef DEBUG_ADD_DEL_ROOTS
- GC_log_printf("Adding data root section %d: %p .. %p\n",
- n_root_sets, b, e);
+ GC_log_printf("Adding data root section %d: %p .. %p%s\n",
+ n_root_sets, b, e, tmp ? " (temporary)" : "");
# endif
GC_static_roots[n_root_sets].r_start = (ptr_t)b;
GC_static_roots[n_root_sets].r_end = (ptr_t)e;
@@ -284,8 +284,9 @@ GC_API void GC_CALL GC_clear_roots(void)
STATIC void GC_remove_root_at_pos(int i)
{
# ifdef DEBUG_ADD_DEL_ROOTS
- GC_log_printf("Remove data root section %d: %p .. %p\n",
- i, GC_static_roots[i].r_start, GC_static_roots[i].r_end);
+ GC_log_printf("Remove data root section at %d: %p .. %p%s\n",
+ i, GC_static_roots[i].r_start, GC_static_roots[i].r_end,
+ GC_static_roots[i].r_tmp ? " (temporary)" : "");
# endif
GC_root_size -= (GC_static_roots[i].r_end - GC_static_roots[i].r_start);
GC_static_roots[i].r_start = GC_static_roots[n_root_sets-1].r_start;