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

#include <concurrent-marking.h>

Collaboration diagram for v8::internal::ConcurrentMarking:

Classes

class  JobTaskMajor
 
class  JobTaskMinor
 
class  MinorMarkingState
 
struct  TaskState
 

Public Member Functions

 ConcurrentMarking (Heap *heap, WeakObjects *weak_objects)
 
 ~ConcurrentMarking ()
 
void TryScheduleJob (GarbageCollector garbage_collector, TaskPriority priority=TaskPriority::kUserVisible)
 
void Join ()
 
void JoinJobForTesting ()
 
bool Pause ()
 
void RescheduleJobIfNeeded (GarbageCollector garbage_collector, TaskPriority priority=TaskPriority::kUserVisible)
 
void FlushNativeContexts (NativeContextStats *main_stats)
 
void FlushMemoryChunkData ()
 
void FlushPretenuringFeedback ()
 
bool IsStopped ()
 
size_t TotalMarkedBytes ()
 
void set_another_ephemeron_iteration (bool another_ephemeron_iteration)
 
bool another_ephemeron_iteration ()
 
GarbageCollector garbage_collector () const
 
bool IsWorkLeft () const
 
size_t FetchAndResetConcurrencyEstimate ()
 
template<YoungGenerationMarkingVisitationMode marking_mode>
V8_INLINE size_t RunMinorImpl (JobDelegate *delegate, TaskState *task_state)
 

Private Member Functions

void RunMinor (JobDelegate *delegate)
 
template<YoungGenerationMarkingVisitationMode marking_mode>
size_t RunMinorImpl (JobDelegate *delegate, TaskState *task_state)
 
void RunMajor (JobDelegate *delegate, base::EnumSet< CodeFlushMode > code_flush_mode, unsigned mark_compact_epoch, bool should_keep_ages_unchanged)
 
size_t GetMajorMaxConcurrency (size_t worker_count)
 
size_t GetMinorMaxConcurrency (size_t worker_count)
 
void Resume ()
 

Private Attributes

std::unique_ptr< JobHandlejob_handle_
 
Heap *const heap_
 
std::optional< GarbageCollectorgarbage_collector_
 
MarkingWorklistsmarking_worklists_
 
WeakObjects *const weak_objects_
 
std::vector< std::unique_ptr< TaskState > > task_state_
 
std::atomic< size_ttotal_marked_bytes_ {0}
 
std::atomic< boolanother_ephemeron_iteration_ {false}
 
std::optional< uint64_t > current_job_trace_id_
 
std::unique_ptr< MinorMarkingStateminor_marking_state_
 
std::atomic< size_testimate_concurrency_ {0}
 

Friends

class Heap
 

Detailed Description

Definition at line 35 of file concurrent-marking.h.

Constructor & Destructor Documentation

◆ ConcurrentMarking()

v8::internal::ConcurrentMarking::ConcurrentMarking ( Heap * heap,
WeakObjects * weak_objects )

Definition at line 327 of file concurrent-marking.cc.

Here is the call graph for this function:

◆ ~ConcurrentMarking()

v8::internal::ConcurrentMarking::~ConcurrentMarking ( )
default

Member Function Documentation

◆ another_ephemeron_iteration()

bool v8::internal::ConcurrentMarking::another_ephemeron_iteration ( )
inline

Definition at line 77 of file concurrent-marking.h.

Here is the caller graph for this function:

◆ FetchAndResetConcurrencyEstimate()

size_t v8::internal::ConcurrentMarking::FetchAndResetConcurrencyEstimate ( )
inline

Definition at line 88 of file concurrent-marking.h.

Here is the caller graph for this function:

◆ FlushMemoryChunkData()

void v8::internal::ConcurrentMarking::FlushMemoryChunkData ( )

Definition at line 852 of file concurrent-marking.cc.

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

◆ FlushNativeContexts()

void v8::internal::ConcurrentMarking::FlushNativeContexts ( NativeContextStats * main_stats)

Definition at line 844 of file concurrent-marking.cc.

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

◆ FlushPretenuringFeedback()

void v8::internal::ConcurrentMarking::FlushPretenuringFeedback ( )

Definition at line 786 of file concurrent-marking.cc.

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

◆ garbage_collector()

GarbageCollector v8::internal::ConcurrentMarking::garbage_collector ( ) const
inline

Definition at line 81 of file concurrent-marking.h.

Here is the caller graph for this function:

◆ GetMajorMaxConcurrency()

size_t v8::internal::ConcurrentMarking::GetMajorMaxConcurrency ( size_t worker_count)
private

Definition at line 615 of file concurrent-marking.cc.

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

◆ GetMinorMaxConcurrency()

size_t v8::internal::ConcurrentMarking::GetMinorMaxConcurrency ( size_t worker_count)
private

Definition at line 631 of file concurrent-marking.cc.

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

◆ IsStopped()

bool v8::internal::ConcurrentMarking::IsStopped ( )

Definition at line 827 of file concurrent-marking.cc.

Here is the caller graph for this function:

◆ IsWorkLeft()

bool v8::internal::ConcurrentMarking::IsWorkLeft ( ) const

Definition at line 729 of file concurrent-marking.cc.

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

◆ Join()

void v8::internal::ConcurrentMarking::Join ( )

Definition at line 795 of file concurrent-marking.cc.

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

◆ JoinJobForTesting()

void v8::internal::ConcurrentMarking::JoinJobForTesting ( )

Definition at line 808 of file concurrent-marking.cc.

◆ Pause()

bool v8::internal::ConcurrentMarking::Pause ( )

Definition at line 813 of file concurrent-marking.cc.

Here is the caller graph for this function:

◆ RescheduleJobIfNeeded()

void v8::internal::ConcurrentMarking::RescheduleJobIfNeeded ( GarbageCollector garbage_collector,
TaskPriority priority = TaskPriority::kUserVisible )

Definition at line 742 of file concurrent-marking.cc.

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

◆ Resume()

void v8::internal::ConcurrentMarking::Resume ( )
private

Definition at line 833 of file concurrent-marking.cc.

Here is the call graph for this function:

◆ RunMajor()

void v8::internal::ConcurrentMarking::RunMajor ( JobDelegate * delegate,
base::EnumSet< CodeFlushMode > code_flush_mode,
unsigned mark_compact_epoch,
bool should_keep_ages_unchanged )
private

Definition at line 348 of file concurrent-marking.cc.

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

◆ RunMinor()

void v8::internal::ConcurrentMarking::RunMinor ( JobDelegate * delegate)
private

Definition at line 577 of file concurrent-marking.cc.

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

◆ RunMinorImpl() [1/2]

template<YoungGenerationMarkingVisitationMode marking_mode>
V8_INLINE size_t v8::internal::ConcurrentMarking::RunMinorImpl ( JobDelegate * delegate,
TaskState * task_state )

Definition at line 516 of file concurrent-marking.cc.

Here is the call graph for this function:

◆ RunMinorImpl() [2/2]

template<YoungGenerationMarkingVisitationMode marking_mode>
size_t v8::internal::ConcurrentMarking::RunMinorImpl ( JobDelegate * delegate,
TaskState * task_state )
private
Here is the caller graph for this function:

◆ set_another_ephemeron_iteration()

void v8::internal::ConcurrentMarking::set_another_ephemeron_iteration ( bool another_ephemeron_iteration)
inline

Definition at line 74 of file concurrent-marking.h.

Here is the caller graph for this function:

◆ TotalMarkedBytes()

size_t v8::internal::ConcurrentMarking::TotalMarkedBytes ( )

Definition at line 866 of file concurrent-marking.cc.

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

◆ TryScheduleJob()

void v8::internal::ConcurrentMarking::TryScheduleJob ( GarbageCollector garbage_collector,
TaskPriority priority = TaskPriority::kUserVisible )

Definition at line 646 of file concurrent-marking.cc.

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

Friends And Related Symbol Documentation

◆ Heap

friend class Heap
friend

Definition at line 122 of file concurrent-marking.h.

Member Data Documentation

◆ another_ephemeron_iteration_

std::atomic<bool> v8::internal::ConcurrentMarking::another_ephemeron_iteration_ {false}
private

Definition at line 117 of file concurrent-marking.h.

◆ current_job_trace_id_

std::optional<uint64_t> v8::internal::ConcurrentMarking::current_job_trace_id_
private

Definition at line 118 of file concurrent-marking.h.

◆ estimate_concurrency_

std::atomic<size_t> v8::internal::ConcurrentMarking::estimate_concurrency_ {0}
private

Definition at line 120 of file concurrent-marking.h.

◆ garbage_collector_

std::optional<GarbageCollector> v8::internal::ConcurrentMarking::garbage_collector_
private

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

◆ heap_

Heap* const v8::internal::ConcurrentMarking::heap_
private

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

◆ job_handle_

std::unique_ptr<JobHandle> v8::internal::ConcurrentMarking::job_handle_
private

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

◆ marking_worklists_

MarkingWorklists* v8::internal::ConcurrentMarking::marking_worklists_
private

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

◆ minor_marking_state_

std::unique_ptr<MinorMarkingState> v8::internal::ConcurrentMarking::minor_marking_state_
private

Definition at line 119 of file concurrent-marking.h.

◆ task_state_

std::vector<std::unique_ptr<TaskState> > v8::internal::ConcurrentMarking::task_state_
private

Definition at line 115 of file concurrent-marking.h.

◆ total_marked_bytes_

std::atomic<size_t> v8::internal::ConcurrentMarking::total_marked_bytes_ {0}
private

Definition at line 116 of file concurrent-marking.h.

◆ weak_objects_

WeakObjects* const v8::internal::ConcurrentMarking::weak_objects_
private

Definition at line 114 of file concurrent-marking.h.


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