Avoid potential data race during apply_to_each_object(reset_back_edge)
authorIvan Maidanski <ivmai@mail.ru>
Tue, 10 Apr 2018 08:07:08 +0000 (11:07 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Tue, 10 Apr 2018 08:07:08 +0000 (11:07 +0300)
commitd7ea0b1082b85c1c868864357db015668240bdf1
tree6f608c4f0a3d21ef3e83a692b9842967d735409f
parenteeab59b3015c8629edeadcf097d0a12515cc8ccd
Avoid potential data race during apply_to_each_object(reset_back_edge)

* backgraph.c [MAKE_BACK_GRAPH] (GC_print_back_graph_stats): Add
assertion that the allocation lock is held; store GC_deepest_obj to
obj local variable (while holding the lock); place UNLOCK/LOCK around
GC_print_heap_obj() call; pass obj to GC_print_heap_obj().
* finalize.c [MAKE_BACK_GRAPH] (GC_notify_or_invoke_finalizers): Remove
UNLOCK/LOCK around GC_print_back_graph_stats() call.
backgraph.c
finalize.c