[handles] Use v8_flags for accessing flag values
Avoid the deprecated FLAG_* syntax, access flag values via the {v8_flags} struct instead. R=dinfuehr@chromium.org Bug: v8:12887 Change-Id: Icc9e1d2db58999b676477924284f78043cf5533c Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3899124 Reviewed-by: Dominik Inführ <dinfuehr@chromium.org> Commit-Queue: Clemens Backes <clemensb@chromium.org> Cr-Commit-Position: refs/heads/main@{#83263}
This commit is contained in:
parent
1047e423a2
commit
2523e6c1d6
@ -817,7 +817,7 @@ Handle<Object> GlobalHandles::CopyGlobal(Address* location) {
|
||||
GlobalHandles* global_handles =
|
||||
Node::FromLocation(location)->global_handles();
|
||||
#ifdef VERIFY_HEAP
|
||||
if (i::FLAG_verify_heap) {
|
||||
if (v8_flags.verify_heap) {
|
||||
Object(*location).ObjectVerify(global_handles->isolate());
|
||||
}
|
||||
#endif // VERIFY_HEAP
|
||||
@ -847,7 +847,7 @@ void GlobalHandles::CopyTracedReference(const Address* const* from,
|
||||
TracedNode::Verify(from);
|
||||
TracedNode::Verify(to);
|
||||
#ifdef VERIFY_HEAP
|
||||
if (i::FLAG_verify_heap) {
|
||||
if (v8_flags.verify_heap) {
|
||||
Object(**to).ObjectVerify(global_handles->isolate());
|
||||
}
|
||||
#endif // VERIFY_HEAP
|
||||
@ -1022,7 +1022,7 @@ void GlobalHandles::IterateWeakRootsForPhantomHandles(
|
||||
|
||||
void GlobalHandles::ComputeWeaknessForYoungObjects(
|
||||
WeakSlotCallback is_unmodified) {
|
||||
if (!FLAG_reclaim_unmodified_wrappers) return;
|
||||
if (!v8_flags.reclaim_unmodified_wrappers) return;
|
||||
|
||||
// Treat all objects as roots during incremental marking to avoid corrupting
|
||||
// marking worklists.
|
||||
@ -1068,7 +1068,7 @@ void GlobalHandles::ProcessWeakYoungObjects(
|
||||
}
|
||||
}
|
||||
|
||||
if (!FLAG_reclaim_unmodified_wrappers) return;
|
||||
if (!v8_flags.reclaim_unmodified_wrappers) return;
|
||||
|
||||
auto* const handler = isolate()->heap()->GetEmbedderRootsHandler();
|
||||
for (TracedNode* node : traced_young_nodes_) {
|
||||
@ -1220,7 +1220,7 @@ void GlobalHandles::PostGarbageCollectionProcessing(
|
||||
DCHECK_EQ(Heap::NOT_IN_GC, isolate_->heap()->gc_state());
|
||||
|
||||
const bool synchronous_second_pass =
|
||||
FLAG_optimize_for_size || FLAG_predictable ||
|
||||
v8_flags.optimize_for_size || v8_flags.predictable ||
|
||||
isolate_->heap()->IsTearingDown() ||
|
||||
(gc_callback_flags &
|
||||
(kGCCallbackFlagForced | kGCCallbackFlagCollectAllAvailableGarbage |
|
||||
|
@ -115,7 +115,7 @@ HandleScope& HandleScope::operator=(HandleScope&& other) V8_NOEXCEPT {
|
||||
void HandleScope::CloseScope(Isolate* isolate, Address* prev_next,
|
||||
Address* prev_limit) {
|
||||
#ifdef DEBUG
|
||||
int before = FLAG_check_handle_count ? NumberOfHandles(isolate) : 0;
|
||||
int before = v8_flags.check_handle_count ? NumberOfHandles(isolate) : 0;
|
||||
#endif
|
||||
DCHECK_NOT_NULL(isolate);
|
||||
HandleScopeData* current = isolate->handle_scope_data();
|
||||
@ -136,7 +136,7 @@ void HandleScope::CloseScope(Isolate* isolate, Address* prev_next,
|
||||
static_cast<size_t>(reinterpret_cast<Address>(limit) -
|
||||
reinterpret_cast<Address>(current->next)));
|
||||
#ifdef DEBUG
|
||||
int after = FLAG_check_handle_count ? NumberOfHandles(isolate) : 0;
|
||||
int after = v8_flags.check_handle_count ? NumberOfHandles(isolate) : 0;
|
||||
DCHECK_LT(after - before, kCheckHandleThreshold);
|
||||
DCHECK_LT(before, kCheckHandleThreshold);
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user