Commit 53d9e8b1 authored by Michael Lippautz's avatar Michael Lippautz Committed by V8 LUCI CQ

cppgc: Fix data race in DCHECK in ObjectSizeTrait

The DCHECK must use atomic accessors as well.

Change-Id: I94983c1e38bc9d436f1577509788fc21e3d4e374
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3300143
Auto-Submit: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Omer Katz <omerkatz@chromium.org>
Reviewed-by: 's avatarOmer Katz <omerkatz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78077}
parent cd52c01b
......@@ -26,7 +26,7 @@ size_t BaseObjectSizeTrait::GetObjectSizeForGarbageCollectedMixin(
const auto& header =
BasePage::FromPayload(address)
->ObjectHeaderFromInnerAddress<AccessMode::kAtomic>(address);
DCHECK(!header.IsLargeObject());
DCHECK(!header.IsLargeObject<AccessMode::kAtomic>());
return header.ObjectSize<AccessMode::kAtomic>();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment