Skip to content

Commit

Permalink
Remove asserts that cause false positive race warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
KIwabuchi committed Sep 23, 2023
1 parent e6178cb commit 2a7f29c
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions include/metall/kernel/manager_kernel_impl.ipp
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,6 @@ void *manager_kernel<chnk_no, chnk_sz>::allocate(
return nullptr;
}
assert(offset >= 0);
#if !(defined(__has_feature) && __has_feature(thread_sanitizer))
assert(offset + nbytes <= m_segment_storage.size());
#endif

return priv_to_address(offset);
}
Expand All @@ -117,9 +114,6 @@ void *manager_kernel<chnk_no, chnk_sz>::allocate_aligned(
return nullptr;
}
assert(offset >= 0);
#if !(defined(__has_feature) && __has_feature(thread_sanitizer))
assert(offset + nbytes <= m_segment_storage.size());
#endif

auto *addr = priv_to_address(offset);
assert((uint64_t)addr % alignment == 0);
Expand Down

0 comments on commit 2a7f29c

Please sign in to comment.