Commit 3ec397b7 authored by Ulan Degenbaev's avatar Ulan Degenbaev Committed by Commit Bot

[heap] Update comments in SlotSet

Bug: chromium:648568
Change-Id: I09ef3911d1817b57d5984ca4121b2579093a1d93
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1722563Reviewed-by: 's avatarDominik Inführ <dinfuehr@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#63037}
parent b1db8d84
......@@ -52,9 +52,6 @@ class SlotSet : public Malloced {
void SetPageStart(Address page_start) { page_start_ = page_start; }
// The slot offset specifies a slot at address page_start_ + slot_offset.
// This method should only be called on the main thread because concurrent
// allocation of the bucket is not thread-safe.
//
// AccessMode defines whether there can be concurrent access on the buckets
// or not.
template <AccessMode access_mode = AccessMode::ATOMIC>
......@@ -181,7 +178,10 @@ class SlotSet : public Malloced {
// Iterate over all slots in the set and for each slot invoke the callback.
// If the callback returns REMOVE_SLOT then the slot is removed from the set.
// Returns the new number of slots.
// This method should only be called on the main thread.
//
// Iteration can be performed concurrently with other operations that use
// atomic access mode such as insertion and removal. However there is no
// guarantee about ordering and linearizability.
//
// Sample usage:
// Iterate([](MaybeObjectSlot slot) {
......
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