18 block_limit_(nullptr),
28#if ENABLE_GLOBAL_HANDLE_ZAPPING
47void PersistentHandles::CheckOwnerIsNotParked() {
51bool PersistentHandles::Contains(
Address* location) {
52 auto it = ordered_blocks_.upper_bound(location);
53 if (it == ordered_blocks_.begin())
return false;
75 ordered_blocks_.insert(block_start);
90 for (
int i = 0; i < static_cast<int>(
blocks_.size()) - 1;
i++) {
110 persistent_handles->
prev_ =
nullptr;
117 if (persistent_handles->
next_)
119 if (persistent_handles->
prev_)
126 isolate->heap()->safepoint()->AssertActive();
128 current = current->
next_) {
129 current->Iterate(visitor);
134 :
impl_(isolate->handle_scope_implementer()) {
142 prev_level_ = data->level;
148 data->next = new_next;
149 data->limit = new_limit;
153 DCHECK(handles_detached_);
164 handles_detached_ =
true;
171 return isolate->handle_scope_implementer()->HasPersistentScope();
internal::Address * GetSpareOrNewBlock()
void BeginPersistentScope()
Isolate * isolate() const
DetachableVector< Address * > * blocks()
std::unique_ptr< PersistentHandles > DetachPersistent(Address *first_block)
V8_INLINE HandleScopeData * handle_scope_data()
PersistentHandlesList * persistent_handles_list() const
base::Mutex persistent_handles_mutex_
void Iterate(RootVisitor *visitor, Isolate *isolate)
void Remove(PersistentHandles *persistent_handles)
void Add(PersistentHandles *persistent_handles)
PersistentHandles * persistent_handles_head_
HandleScopeImplementer *const impl_
V8_EXPORT_PRIVATE ~PersistentHandlesScope()
static V8_EXPORT_PRIVATE bool IsActive(Isolate *isolate)
V8_EXPORT_PRIVATE std::unique_ptr< PersistentHandles > Detach()
V8_EXPORT_PRIVATE PersistentHandlesScope(Isolate *isolate)
V8_EXPORT_PRIVATE Address * GetHandle(Address value)
V8_EXPORT_PRIVATE PersistentHandles(Isolate *isolate)
std::vector< Address * > blocks_
PersistentHandles * next_
V8_EXPORT_PRIVATE ~PersistentHandles()
PersistentHandles * prev_
V8_EXPORT_PRIVATE void Iterate(RootVisitor *visitor)
virtual void VisitRootPointers(Root root, const char *description, FullObjectSlot start, FullObjectSlot end)=0
constexpr uint32_t kPersistentHandleZapValue
void DeleteArray(T *array)
const int kHandleBlockSize
T * NewArray(size_t size)
#define DCHECK_LE(v1, v2)
#define DCHECK_NOT_NULL(val)
#define DCHECK(condition)
#define DCHECK_LT(v1, v2)
#define DCHECK_EQ(v1, v2)