v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
v8::internal::MarkingBarrier Class Reference

#include <marking-barrier.h>

Collaboration diagram for v8::internal::MarkingBarrier:

Public Member Functions

 MarkingBarrier (LocalHeap *)
 
 ~MarkingBarrier ()
 
void Activate (bool is_compacting, MarkingMode marking_mode)
 
void Deactivate ()
 
void PublishIfNeeded ()
 
void ActivateShared ()
 
void DeactivateShared ()
 
void PublishSharedIfNeeded ()
 
template<typename TSlot >
void Write (Tagged< HeapObject > host, TSlot slot, Tagged< HeapObject > value)
 
void Write (Tagged< HeapObject > host, IndirectPointerSlot slot)
 
void Write (Tagged< InstructionStream > host, RelocInfo *, Tagged< HeapObject > value)
 
void Write (Tagged< JSArrayBuffer > host, ArrayBufferExtension *)
 
void Write (Tagged< DescriptorArray >, int number_of_own_descriptors)
 
void WriteWithoutHost (Tagged< HeapObject > value)
 
void MarkValue (Tagged< HeapObject > host, Tagged< HeapObject > value)
 
bool is_minor () const
 
bool is_not_major () const
 
Heapheap () const
 

Static Public Member Functions

static void ActivateAll (Heap *heap, bool is_compacting)
 
static void DeactivateAll (Heap *heap)
 
static V8_EXPORT_PRIVATE void PublishAll (Heap *heap)
 
static void ActivateYoung (Heap *heap)
 
static void DeactivateYoung (Heap *heap)
 
static V8_EXPORT_PRIVATE void PublishYoung (Heap *heap)
 

Private Member Functions

void MarkValueShared (Tagged< HeapObject > value)
 
void MarkValueLocal (Tagged< HeapObject > value)
 
void RecordRelocSlot (Tagged< InstructionStream > host, RelocInfo *rinfo, Tagged< HeapObject > target)
 
bool IsCurrentMarkingBarrier (Tagged< HeapObject > verification_candidate)
 
template<typename TSlot >
void MarkRange (Tagged< HeapObject > value, TSlot start, TSlot end)
 
bool IsCompacting (Tagged< HeapObject > object) const
 
bool is_major () const
 
Isolateisolate () const
 

Private Attributes

Heapheap_
 
MarkCompactCollectormajor_collector_
 
MinorMarkSweepCollectorminor_collector_
 
IncrementalMarkingincremental_marking_
 
std::unique_ptr< MarkingWorklists::Localcurrent_worklists_
 
std::optional< MarkingWorklists::Localshared_heap_worklists_
 
MarkingState marking_state_
 
std::unordered_map< MutablePageMetadata *, std::unique_ptr< TypedSlots >, base::hash< MutablePageMetadata * > > typed_slots_map_
 
bool is_compacting_ = false
 
bool is_activated_ = false
 
const bool is_main_thread_barrier_
 
const bool uses_shared_heap_
 
const bool is_shared_space_isolate_
 
MarkingMode marking_mode_ = MarkingMode::kNoMarking
 

Detailed Description

Definition at line 26 of file marking-barrier.h.

Constructor & Destructor Documentation

◆ MarkingBarrier()

v8::internal::MarkingBarrier::MarkingBarrier ( LocalHeap * local_heap)
explicit

Definition at line 32 of file marking-barrier.cc.

◆ ~MarkingBarrier()

v8::internal::MarkingBarrier::~MarkingBarrier ( )

Definition at line 42 of file marking-barrier.cc.

Member Function Documentation

◆ Activate()

void v8::internal::MarkingBarrier::Activate ( bool is_compacting,
MarkingMode marking_mode )

Definition at line 345 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ActivateAll()

void v8::internal::MarkingBarrier::ActivateAll ( Heap * heap,
bool is_compacting )
static

Definition at line 312 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ActivateShared()

void v8::internal::MarkingBarrier::ActivateShared ( )

Definition at line 355 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ActivateYoung()

void v8::internal::MarkingBarrier::ActivateYoung ( Heap * heap)
static

Definition at line 337 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Deactivate()

void v8::internal::MarkingBarrier::Deactivate ( )

Definition at line 398 of file marking-barrier.cc.

Here is the caller graph for this function:

◆ DeactivateAll()

void v8::internal::MarkingBarrier::DeactivateAll ( Heap * heap)
static

Definition at line 363 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ DeactivateShared()

void v8::internal::MarkingBarrier::DeactivateShared ( )

Definition at line 408 of file marking-barrier.cc.

Here is the caller graph for this function:

◆ DeactivateYoung()

void v8::internal::MarkingBarrier::DeactivateYoung ( Heap * heap)
static

Definition at line 390 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ heap()

Heap * v8::internal::MarkingBarrier::heap ( ) const
inline

Definition at line 72 of file marking-barrier.h.

Here is the caller graph for this function:

◆ is_major()

bool v8::internal::MarkingBarrier::is_major ( ) const
inlineprivate

Definition at line 94 of file marking-barrier.h.

Here is the caller graph for this function:

◆ is_minor()

bool v8::internal::MarkingBarrier::is_minor ( ) const
inline

Definition at line 60 of file marking-barrier.h.

Here is the caller graph for this function:

◆ is_not_major()

bool v8::internal::MarkingBarrier::is_not_major ( ) const
inline

Definition at line 62 of file marking-barrier.h.

◆ IsCompacting()

bool v8::internal::MarkingBarrier::IsCompacting ( Tagged< HeapObject > object) const
inlineprivate

Definition at line 133 of file marking-barrier-inl.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ IsCurrentMarkingBarrier()

bool v8::internal::MarkingBarrier::IsCurrentMarkingBarrier ( Tagged< HeapObject > verification_candidate)
private

Definition at line 461 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ isolate()

Isolate * v8::internal::MarkingBarrier::isolate ( ) const
private

Definition at line 466 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MarkRange()

template<typename TSlot >
void v8::internal::MarkingBarrier::MarkRange ( Tagged< HeapObject > value,
TSlot start,
TSlot end )
inlineprivate

Definition at line 114 of file marking-barrier-inl.h.

Here is the call graph for this function:

◆ MarkValue()

void v8::internal::MarkingBarrier::MarkValue ( Tagged< HeapObject > host,
Tagged< HeapObject > value )
inline

Definition at line 34 of file marking-barrier-inl.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MarkValueLocal()

void v8::internal::MarkingBarrier::MarkValueLocal ( Tagged< HeapObject > value)
inlineprivate

Definition at line 88 of file marking-barrier-inl.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MarkValueShared()

void v8::internal::MarkingBarrier::MarkValueShared ( Tagged< HeapObject > value)
inlineprivate

Definition at line 74 of file marking-barrier-inl.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PublishAll()

void v8::internal::MarkingBarrier::PublishAll ( Heap * heap)
static

Definition at line 414 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PublishIfNeeded()

void v8::internal::MarkingBarrier::PublishIfNeeded ( )

Definition at line 439 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PublishSharedIfNeeded()

void v8::internal::MarkingBarrier::PublishSharedIfNeeded ( )

Definition at line 455 of file marking-barrier.cc.

Here is the caller graph for this function:

◆ PublishYoung()

void v8::internal::MarkingBarrier::PublishYoung ( Heap * heap)
static

Definition at line 433 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ RecordRelocSlot()

void v8::internal::MarkingBarrier::RecordRelocSlot ( Tagged< InstructionStream > host,
RelocInfo * rinfo,
Tagged< HeapObject > target )
private

Definition at line 199 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Write() [1/5]

void v8::internal::MarkingBarrier::Write ( Tagged< DescriptorArray > descriptor_array,
int number_of_own_descriptors )

Definition at line 143 of file marking-barrier.cc.

Here is the call graph for this function:

◆ Write() [2/5]

void v8::internal::MarkingBarrier::Write ( Tagged< HeapObject > host,
IndirectPointerSlot slot )

Definition at line 44 of file marking-barrier.cc.

Here is the call graph for this function:

◆ Write() [3/5]

template<typename TSlot >
void v8::internal::MarkingBarrier::Write ( Tagged< HeapObject > host,
TSlot slot,
Tagged< HeapObject > value )

Definition at line 21 of file marking-barrier-inl.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Write() [4/5]

void v8::internal::MarkingBarrier::Write ( Tagged< InstructionStream > host,
RelocInfo * reloc_info,
Tagged< HeapObject > value )

Definition at line 107 of file marking-barrier.cc.

Here is the call graph for this function:

◆ Write() [5/5]

void v8::internal::MarkingBarrier::Write ( Tagged< JSArrayBuffer > host,
ArrayBufferExtension * extension )

Definition at line 128 of file marking-barrier.cc.

Here is the call graph for this function:

◆ WriteWithoutHost()

void v8::internal::MarkingBarrier::WriteWithoutHost ( Tagged< HeapObject > value)

Definition at line 91 of file marking-barrier.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ current_worklists_

std::unique_ptr<MarkingWorklists::Local> v8::internal::MarkingBarrier::current_worklists_
private

Definition at line 102 of file marking-barrier.h.

◆ heap_

Heap* v8::internal::MarkingBarrier::heap_
private

Definition at line 98 of file marking-barrier.h.

◆ incremental_marking_

IncrementalMarking* v8::internal::MarkingBarrier::incremental_marking_
private

Definition at line 101 of file marking-barrier.h.

◆ is_activated_

bool v8::internal::MarkingBarrier::is_activated_ = false
private

Definition at line 109 of file marking-barrier.h.

◆ is_compacting_

bool v8::internal::MarkingBarrier::is_compacting_ = false
private

Definition at line 108 of file marking-barrier.h.

◆ is_main_thread_barrier_

const bool v8::internal::MarkingBarrier::is_main_thread_barrier_
private

Definition at line 110 of file marking-barrier.h.

◆ is_shared_space_isolate_

const bool v8::internal::MarkingBarrier::is_shared_space_isolate_
private

Definition at line 112 of file marking-barrier.h.

◆ major_collector_

MarkCompactCollector* v8::internal::MarkingBarrier::major_collector_
private

Definition at line 99 of file marking-barrier.h.

◆ marking_mode_

MarkingMode v8::internal::MarkingBarrier::marking_mode_ = MarkingMode::kNoMarking
private

Definition at line 113 of file marking-barrier.h.

◆ marking_state_

MarkingState v8::internal::MarkingBarrier::marking_state_
private

Definition at line 104 of file marking-barrier.h.

◆ minor_collector_

MinorMarkSweepCollector* v8::internal::MarkingBarrier::minor_collector_
private

Definition at line 100 of file marking-barrier.h.

◆ shared_heap_worklists_

std::optional<MarkingWorklists::Local> v8::internal::MarkingBarrier::shared_heap_worklists_
private

Definition at line 103 of file marking-barrier.h.

◆ typed_slots_map_

std::unordered_map<MutablePageMetadata*, std::unique_ptr<TypedSlots>, base::hash<MutablePageMetadata*> > v8::internal::MarkingBarrier::typed_slots_map_
private

Definition at line 107 of file marking-barrier.h.

◆ uses_shared_heap_

const bool v8::internal::MarkingBarrier::uses_shared_heap_
private

Definition at line 111 of file marking-barrier.h.


The documentation for this class was generated from the following files: