summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIvan Maidanski <ivmai@mail.ru>2023-04-27 08:27:09 +0300
committerIvan Maidanski <ivmai@mail.ru>2023-04-27 13:28:08 +0300
commit80198d314e516fc15f553b73c0880a33f1bf4548 (patch)
tree23046d4fb656d316b84e0035c945552aa46fe549
parent7334cc94a04bf188762c99b2e4bfc932e508bdc2 (diff)
downloadbdwgc-80198d314e516fc15f553b73c0880a33f1bf4548.tar.gz
Suppress a data race report in debug-related GC_n_set_marks
There could be a race between GC_clear_hdr_marks and GC_n_set_marks but the latter is for a debug purpose. * reclaim.c [USE_MARK_BYTES] (GC_n_set_marks): Add GC_ATTR_NO_SANITIZE_THREAD attribute; update comment.
-rw-r--r--reclaim.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/reclaim.c b/reclaim.c
index 5b9498c7..7b0e573c 100644
--- a/reclaim.c
+++ b/reclaim.c
@@ -488,6 +488,9 @@ struct Print_stats
/* Return the number of set mark bits in the given header. */
/* Remains externally visible as used by GNU GCJ currently. */
+/* There could be a race between GC_clear_hdr_marks and this */
+/* function but the latter is for a debug purpose. */
+GC_ATTR_NO_SANITIZE_THREAD
unsigned GC_n_set_marks(hdr *hhdr)
{
unsigned result = 0;