![]() |
v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
|
#include <fixed-array.h>
Public Types | |
using | Header = detail::TaggedArrayHeader<ShapeT, Super> |
using | Shape = ShapeT |
Public Member Functions | |
Tagged< ElementT > | get (int index) const |
Tagged< ElementT > | get (int index, RelaxedLoadTag) const |
Tagged< ElementT > | get (int index, AcquireLoadTag) const |
Tagged< ElementT > | get (int index, SeqCstAccessTag) const |
void | set (int index, Tagged< ElementT > value, WriteBarrierMode mode=kDefaultMode) |
template<typename T = ElementT, typename = std::enable_if<kSupportsSmiElements<T>>> | |
void | set (int index, Tagged< Smi > value) |
void | set (int index, Tagged< ElementT > value, RelaxedStoreTag, WriteBarrierMode mode=kDefaultMode) |
template<typename T = ElementT, typename = std::enable_if<kSupportsSmiElements<T>>> | |
void | set (int index, Tagged< Smi > value, RelaxedStoreTag) |
void | set (int index, Tagged< ElementT > value, ReleaseStoreTag, WriteBarrierMode mode=kDefaultMode) |
template<typename T = ElementT, typename = std::enable_if<kSupportsSmiElements<T>>> | |
void | set (int index, Tagged< Smi > value, ReleaseStoreTag) |
void | set (int index, Tagged< ElementT > value, SeqCstAccessTag, WriteBarrierMode mode=kDefaultMode) |
template<typename T = ElementT, typename = std::enable_if<kSupportsSmiElements<T>>> | |
void | set (int index, Tagged< Smi > value, SeqCstAccessTag) |
Tagged< ElementT > | swap (int index, Tagged< ElementT > value, SeqCstAccessTag, WriteBarrierMode mode=kDefaultMode) |
Tagged< ElementT > | compare_and_swap (int index, Tagged< ElementT > expected, Tagged< ElementT > value, SeqCstAccessTag, WriteBarrierMode mode=kDefaultMode) |
void | RightTrim (Isolate *isolate, int new_capacity) |
int | AllocatedSize () const |
SlotType | RawFieldOfFirstElement () const |
SlotType | RawFieldOfElementAt (int index) const |
template<class IsolateT > | |
Handle< D > | Allocate (IsolateT *isolate, int capacity, std::optional< DisallowGarbageCollection > *no_gc_out, AllocationType allocation) |
Static Public Member Functions | |
static void | MoveElements (Isolate *isolate, Tagged< Derived > dst, int dst_index, Tagged< Derived > src, int src_index, int len, WriteBarrierMode mode=kDefaultMode) |
static void | CopyElements (Isolate *isolate, Tagged< Derived > dst, int dst_index, Tagged< Derived > src, int src_index, int len, WriteBarrierMode mode=kDefaultMode) |
static constexpr int | SizeFor (int capacity) |
static constexpr int | OffsetOfElementAt (int index) |
Static Public Attributes | |
static constexpr bool | kElementsAreMaybeObject = is_maybe_weak_v<ElementT> |
static constexpr int | kElementSize = kTaggedSize |
static constexpr int | kMaxCapacity = kMaxFixedArrayCapacity |
static constexpr int | kMaxRegularCapacity |
Protected Member Functions | |
bool | IsInBounds (int index) const |
bool | IsCowArray () const |
FLEXIBLE_ARRAY_MEMBER (ElementMemberT, objects) | |
Static Protected Member Functions | |
template<class IsolateT > | |
static Handle< Derived > | Allocate (IsolateT *isolate, int capacity, std::optional< DisallowGarbageCollection > *no_gc_out, AllocationType allocation=AllocationType::kYoung) |
static constexpr int | NewCapacityForIndex (int index, int old_capacity) |
Private Types | |
using | ElementT = typename ShapeT::ElementT |
using | ElementMemberT |
using | SlotType |
Static Private Attributes | |
template<typename ElementT > | |
static constexpr bool | kSupportsSmiElements |
static constexpr WriteBarrierMode | kDefaultMode |
Definition at line 92 of file fixed-array.h.
|
private |
Definition at line 99 of file fixed-array.h.
|
private |
Definition at line 94 of file fixed-array.h.
using v8::internal::TaggedArrayBase< Derived, ShapeT, Super >::Header = detail::TaggedArrayHeader<ShapeT, Super> |
Definition at line 110 of file fixed-array.h.
using v8::internal::TaggedArrayBase< Derived, ShapeT, Super >::Shape = ShapeT |
Definition at line 119 of file fixed-array.h.
|
private |
Definition at line 115 of file fixed-array.h.
Handle< D > v8::internal::TaggedArrayBase< Derived, ShapeT, Super >::Allocate | ( | IsolateT * | isolate, |
int | capacity, | ||
std::optional< DisallowGarbageCollection > * | no_gc_out, | ||
AllocationType | allocation ) |
|
staticprotected |
|
inline |
Definition at line 273 of file fixed-array-inl.h.
|
inline |
Definition at line 213 of file fixed-array-inl.h.
|
inlinestatic |
Definition at line 242 of file fixed-array-inl.h.
|
protected |
|
inline |
Definition at line 115 of file fixed-array-inl.h.
|
inline |
Definition at line 130 of file fixed-array-inl.h.
|
inline |
Definition at line 123 of file fixed-array-inl.h.
|
inline |
Definition at line 137 of file fixed-array-inl.h.
|
inlineprotected |
Definition at line 108 of file fixed-array-inl.h.
|
inlineprotected |
Definition at line 103 of file fixed-array-inl.h.
|
inlinestatic |
Definition at line 223 of file fixed-array-inl.h.
|
staticconstexprprotected |
Definition at line 381 of file fixed-array-inl.h.
|
inlinestaticconstexpr |
|
inline |
Definition at line 285 of file fixed-array-inl.h.
|
inline |
Definition at line 279 of file fixed-array-inl.h.
|
inline |
|
inline |
Definition at line 158 of file fixed-array-inl.h.
|
inline |
Definition at line 173 of file fixed-array-inl.h.
|
inline |
Definition at line 188 of file fixed-array-inl.h.
|
inline |
Definition at line 143 of file fixed-array-inl.h.
|
inline |
Definition at line 153 of file fixed-array-inl.h.
|
inline |
Definition at line 167 of file fixed-array-inl.h.
|
inline |
Definition at line 182 of file fixed-array-inl.h.
|
inline |
Definition at line 197 of file fixed-array-inl.h.
|
inlinestaticconstexpr |
|
inline |
Definition at line 204 of file fixed-array-inl.h.
|
staticconstexprprivate |
Definition at line 106 of file fixed-array.h.
|
staticconstexpr |
Definition at line 111 of file fixed-array.h.
|
staticconstexpr |
Definition at line 112 of file fixed-array.h.
|
staticconstexpr |
Definition at line 187 of file fixed-array.h.
|
staticconstexpr |
Definition at line 191 of file fixed-array.h.
|
staticconstexprprivate |
Definition at line 103 of file fixed-array.h.