v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
cppgc::Heap::HeapOptions Struct Reference

#include <heap.h>

Collaboration diagram for cppgc::Heap::HeapOptions:

Static Public Member Functions

static HeapOptions Default ()
 

Public Attributes

std::vector< std::unique_ptr< CustomSpaceBase > > custom_spaces
 
StackSupport stack_support = StackSupport::kSupportsConservativeStackScan
 
MarkingType marking_support = MarkingType::kIncrementalAndConcurrent
 
SweepingType sweeping_support = SweepingType::kIncrementalAndConcurrent
 
ResourceConstraints resource_constraints
 

Detailed Description

Options specifying Heap properties (e.g. custom spaces) when initializing a heap through Heap::Create().

Definition at line 114 of file heap.h.

Member Function Documentation

◆ Default()

static HeapOptions cppgc::Heap::HeapOptions::Default ( )
inlinestatic

Creates reasonable defaults for instantiating a Heap.

Returns
the HeapOptions that can be passed to Heap::Create().

Definition at line 120 of file heap.h.

Member Data Documentation

◆ custom_spaces

std::vector<std::unique_ptr<CustomSpaceBase> > cppgc::Heap::HeapOptions::custom_spaces

Custom spaces added to heap are required to have indices forming a numbered sequence starting at 0, i.e., their kSpaceIndex must correspond to the index they reside in the vector.

Definition at line 127 of file heap.h.

◆ marking_support

MarkingType cppgc::Heap::HeapOptions::marking_support = MarkingType::kIncrementalAndConcurrent

Specifies which types of marking are supported by the heap.

Definition at line 142 of file heap.h.

◆ resource_constraints

ResourceConstraints cppgc::Heap::HeapOptions::resource_constraints

Resource constraints specifying various properties that the internal GC scheduler follows.

Definition at line 153 of file heap.h.

◆ stack_support

StackSupport cppgc::Heap::HeapOptions::stack_support = StackSupport::kSupportsConservativeStackScan

Specifies whether conservative stack scan is supported. When conservative stack scan is not supported, the collector may try to invoke garbage collections using non-nestable task, which are guaranteed to have no interesting stack, through the provided Platform. If such tasks are not supported by the Platform, the embedder must take care of invoking the GC through ForceGarbageCollectionSlow().

Definition at line 137 of file heap.h.

◆ sweeping_support

SweepingType cppgc::Heap::HeapOptions::sweeping_support = SweepingType::kIncrementalAndConcurrent

Specifies which types of sweeping are supported by the heap.

Definition at line 147 of file heap.h.


The documentation for this struct was generated from the following file: