summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorIvan Maidanski <ivmai@mail.ru>2023-04-11 22:10:09 +0300
committerIvan Maidanski <ivmai@mail.ru>2023-04-11 22:23:14 +0300
commit4c0c2e42923f3e4912d848fd034935650e63fe56 (patch)
treefc43b9e6c7461a4a41d317beaa8504effceafd14 /include
parent6eb3dd3483fa870176ffe6390bd964b67208dce0 (diff)
downloadbdwgc-4c0c2e42923f3e4912d848fd034935650e63fe56.tar.gz
Acquire GC lock in GC_is_tmp_root
* include/gc/gc_mark.h (GC_is_tmp_root): Document function. * include/gc/gc_mark.h (GC_is_tmp_root): Add comment that the function acquires the GC lock. * mark_rts.c [!NO_DEBUGGING] (GC_is_tmp_root): Likewise. * mark_rts.c [!NO_DEBUGGING] (GC_is_tmp_root): Define res local variable; change code to have only single return statement; wrap code into LOCK/UNLOCK.
Diffstat (limited to 'include')
-rw-r--r--include/gc/gc_mark.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/gc/gc_mark.h b/include/gc/gc_mark.h
index ceba353d..6142e750 100644
--- a/include/gc/gc_mark.h
+++ b/include/gc/gc_mark.h
@@ -363,6 +363,8 @@ GC_API void GC_CALL GC_enumerate_reachable_objects_inner(
GC_reachable_object_proc,
void * /* client_data */) GC_ATTR_NONNULL(1);
+/* Is the given address in one of the temporary static root sections? */
+/* Acquires the GC lock. */
GC_API int GC_CALL GC_is_tmp_root(void *);
GC_API void GC_CALL GC_print_trace(GC_word /* gc_no */);