Commit 1525e951 authored by Omer Katz's avatar Omer Katz Committed by V8 LUCI CQ

cppgc: Fix comment

Change-Id: I64c06cad84e613ecfb3c582c1ac8a97f6d4e6692
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3071215
Auto-Submit: Omer Katz <omerkatz@chromium.org>
Commit-Queue: Anton Bikineev <bikineev@chromium.org>
Reviewed-by: 's avatarAnton Bikineev <bikineev@chromium.org>
Cr-Commit-Position: refs/heads/master@{#76102}
parent 671c6648
......@@ -169,12 +169,12 @@ class V8_EXPORT WriteBarrierTypeForCagedHeapPolicy final {
WriteBarrier::Params& params) {
#if V8_OS_WIN || V8_OS_FUCHSIA
// This method assumes that the stack is allocated in high
// addresses. That is not guaranteed on Windows. Having a low-address
// (below api_constants::kCagedHeapReservationSize) on-stack slot with a
// nullptr value would cause this method to erroneously return that the slot
// resides in a caged heap that starts at a null address.
// This check is applied only on Windows because it is not an issue on other
// OSes where the stack resides in higher adderesses, and to keep the write
// addresses. That is not guaranteed on Windows and Fuchsia. Having a
// low-address (below api_constants::kCagedHeapReservationSize) on-stack
// slot with a nullptr value would cause this method to erroneously return
// that the slot resides in a caged heap that starts at a null address. This
// check is applied only on Windows because it is not an issue on other OSes
// where the stack resides in higher adderesses, and to keep the write
// barrier as cheap as possible.
if (!value) return false;
#endif // V8_OS_WIN || V8_OS_FUCHSIA
......
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