V8 Project
|
#include <objects.h>
Classes | |
class | BASE_EMBEDDED |
class | CodePtrCountField |
class | HeapPtrCountField |
class | Int32CountField |
class | Int64CountField |
class | IsExtendedField |
class | TotalCountField |
class | WeakObjectStateField |
Public Types | |
enum | WeakObjectState { NO_WEAK_OBJECTS , WEAK_OBJECTS_IN_OPTIMIZED_CODE , WEAK_OBJECTS_IN_IC } |
enum | Type { INT64 = 0 , CODE_PTR , HEAP_PTR , INT32 , NUMBER_OF_TYPES , FIRST_TYPE = INT64 , LAST_TYPE = INT32 } |
enum | LayoutSection { SMALL_SECTION = 0 , EXTENDED_SECTION , NUMBER_OF_LAYOUT_SECTIONS } |
![]() | |
enum | StoreFromKeyed { MAY_BE_STORE_FROM_KEYED , CERTAINLY_NOT_STORE_FROM_KEYED } |
enum | StorePropertyMode { NORMAL_PROPERTY , SUPER_PROPERTY } |
Public Member Functions | |
int | first_index (Type type, LayoutSection layout_section) |
int | last_index (Type type, LayoutSection layout_section) |
int | number_of_entries (Type type, LayoutSection layout_section) |
Type | get_type (int index) |
bool | offset_is_type (int offset, Type type) |
Address | get_code_ptr_entry (int index) |
Object * | get_heap_ptr_entry (int index) |
int64_t | get_int64_entry (int index) |
int32_t | get_int32_entry (int index) |
double | get_int64_entry_as_double (int index) |
void | set (int index, Address value) |
void | set (int index, Object *value) |
void | set (int index, int64_t value) |
void | set (int index, double value) |
void | set (int index, int32_t value) |
void | set_at_offset (int offset, int32_t value) |
void | set_at_offset (int offset, int64_t value) |
void | set_at_offset (int offset, double value) |
void | set_at_offset (int offset, Address value) |
void | set_at_offset (int offset, Object *value) |
void | set_weak_object_state (WeakObjectState state) |
WeakObjectState | get_weak_object_state () |
bool | is_extended_layout () |
LayoutSection | final_section () |
void | Init (const NumberOfEntries &small) |
void | InitExtended (const NumberOfEntries &small, const NumberOfEntries &extended) |
void | ClearPtrEntries (Isolate *isolate) |
int | length () |
int | size () |
int | OffsetOfElementAt (int index) |
Object ** | RawFieldOfElementAt (int index) |
void | ConstantPoolIterateBody (ObjectVisitor *v) |
![]() | |
Map * | map () const |
void | set_map (Map *value) |
void | set_map_no_write_barrier (Map *value) |
Map * | synchronized_map () |
MapWord | synchronized_map_word () const |
void | synchronized_set_map (Map *value) |
void | synchronized_set_map_no_write_barrier (Map *value) |
void | synchronized_set_map_word (MapWord map_word) |
MapWord | map_word () const |
void | set_map_word (MapWord map_word) |
Heap * | GetHeap () const |
Isolate * | GetIsolate () const |
Address | address () |
void | Iterate (ObjectVisitor *v) |
void | IterateBody (InstanceType type, int object_size, ObjectVisitor *v) |
int | Size () |
bool | MayContainRawValues () |
int | SizeFromMap (Map *map) |
WriteBarrierMode | GetWriteBarrierMode (const DisallowHeapAllocation &promise) |
void | HeapObjectShortPrint (OStream &os) |
STATIC_ASSERT (kMapOffset==Internals::kHeapObjectMapOffset) | |
![]() | |
bool | IsObject () const |
INLINE (bool IsFixedArrayBase() const) | |
INLINE (bool IsExternal() const) | |
INLINE (bool IsAccessorInfo() const) | |
INLINE (bool IsStruct() const) | |
INLINE (bool IsSpecObject()) const | |
INLINE (bool IsSpecFunction()) const | |
INLINE (bool IsTemplateInfo()) const | |
INLINE (bool IsNameDictionary() const) | |
INLINE (bool IsSeededNumberDictionary() const) | |
INLINE (bool IsUnseededNumberDictionary() const) | |
INLINE (bool IsOrderedHashSet() const) | |
INLINE (bool IsOrderedHashMap() const) | |
bool | IsCallable () const |
INLINE (bool IsUndefined() const) | |
INLINE (bool IsNull() const) | |
INLINE (bool IsTheHole() const) | |
INLINE (bool IsException() const) | |
INLINE (bool IsUninitialized() const) | |
INLINE (bool IsTrue() const) | |
INLINE (bool IsFalse() const) | |
INLINE (bool IsArgumentsMarker() const) | |
INLINE (bool IsFiller() const) | |
double | Number () |
INLINE (bool IsNaN() const) | |
INLINE (bool IsMinusZero() const) | |
bool | ToInt32 (int32_t *value) |
bool | ToUint32 (uint32_t *value) |
Representation | OptimalRepresentation () |
bool | FitsRepresentation (Representation representation) |
Handle< HeapType > | OptimalType (Isolate *isolate, Representation representation) |
bool | HasValidElements () |
bool | HasSpecificClassOf (String *name) |
bool | BooleanValue () |
Object * | GetHash () |
bool | SameValue (Object *other) |
bool | SameValueZero (Object *other) |
bool | ToArrayIndex (uint32_t *index) |
bool | IsStringObjectWithCharacterAt (uint32_t index) |
void | VerifyApiCallResultType () |
void | ShortPrint (FILE *out=stdout) |
void | ShortPrint (StringStream *accumulator) |
Static Public Attributes | |
static const int | kSmallLayout1Offset = HeapObject::kHeaderSize |
static const int | kSmallLayout2Offset = kSmallLayout1Offset + kInt32Size |
static const int | kHeaderSize = kSmallLayout2Offset + kInt32Size |
static const int | kFirstEntryOffset = ROUND_UP(kHeaderSize, kInt64Size) |
static const int | kSmallLayoutCountBits = 10 |
static const int | kMaxSmallEntriesPerType = (1 << kSmallLayoutCountBits) - 1 |
static const int | kExtendedInt64CountOffset = 0 |
static const int | kExtendedCodePtrCountOffset |
static const int | kExtendedHeapPtrCountOffset |
static const int | kExtendedInt32CountOffset |
static const int | kExtendedFirstOffset |
![]() | |
static const int | kMapOffset = Object::kHeaderSize |
static const int | kHeaderSize = kMapOffset + kPointerSize |
![]() | |
static const int | kHeaderSize = 0 |
Private Member Functions | |
int | first_extended_section_index () |
int | get_extended_section_header_offset () |
DISALLOW_IMPLICIT_CONSTRUCTORS (ConstantPoolArray) | |
Static Private Member Functions | |
static Type | next_type (Type type) |
Additional Inherited Members | |
![]() | |
void | IteratePointers (ObjectVisitor *v, int start, int end) |
void | IteratePointer (ObjectVisitor *v, int offset) |
void | IterateNextCodeLink (ObjectVisitor *v, int offset) |
Enumerator | |
---|---|
SMALL_SECTION | |
EXTENDED_SECTION | |
NUMBER_OF_LAYOUT_SECTIONS |
Definition at line 2619 of file objects.h.
Enumerator | |
---|---|
NO_WEAK_OBJECTS | |
WEAK_OBJECTS_IN_OPTIMIZED_CODE | |
WEAK_OBJECTS_IN_IC |
Definition at line 2602 of file objects.h.
void v8::internal::ConstantPoolArray::ClearPtrEntries | ( | Isolate * | isolate | ) |
Definition at line 9084 of file objects.cc.
References v8::internal::Builtins::builtin(), v8::internal::Isolate::builtins(), CODE_PTR, v8::internal::Code::entry(), final_section(), first_index(), v8::internal::Isolate::heap(), HEAP_PTR, v8::internal::MemsetPointer(), number_of_entries(), OffsetOfElementAt(), and v8::internal::HeapObject::RawField().
Referenced by v8::internal::Heap::AllocateConstantPoolArray(), and v8::internal::Heap::AllocateExtendedConstantPoolArray().
void v8::internal::ConstantPoolArray::ConstantPoolIterateBody | ( | ObjectVisitor * | v | ) |
Definition at line 9062 of file objects.cc.
References CODE_PTR, final_section(), HEAP_PTR, and RawFieldOfElementAt().
|
private |
Definition at line 2776 of file objects.h.
References v8::internal::kInt32Size, v8::internal::kInt64Size, v8::internal::kPointerSize, and UNREACHABLE.
|
inline |
Definition at line 2363 of file objects-inl.h.
References EXTENDED_SECTION, is_extended_layout(), and SMALL_SECTION.
Referenced by ClearPtrEntries(), and ConstantPoolIterateBody().
|
inlineprivate |
Definition at line 2368 of file objects-inl.h.
References DCHECK, v8::internal::BitFieldBase< T, shift, size, U >::decode(), is_extended_layout(), kSmallLayout2Offset, and READ_UINT32_FIELD.
Referenced by first_index(), and get_type().
|
inline |
Definition at line 2394 of file objects-inl.h.
References DCHECK, EXTENDED_SECTION, first_extended_section_index(), FIRST_TYPE, is_extended_layout(), next_type(), and number_of_entries().
Referenced by ClearPtrEntries(), last_index(), and offset_is_type().
Definition at line 2497 of file objects-inl.h.
References CODE_PTR, DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), v8::internal::HeapObject::map(), OffsetOfElementAt(), and READ_FIELD.
|
inlineprivate |
Definition at line 2375 of file objects-inl.h.
References v8::internal::kInt64Size, v8::internal::RoundUp(), SizeFor(), and SMALL_SECTION.
Referenced by InitExtended(), and number_of_entries().
Definition at line 2504 of file objects-inl.h.
References DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), HEAP_PTR, v8::internal::HeapObject::map(), OffsetOfElementAt(), and READ_FIELD.
|
inline |
Definition at line 2511 of file objects-inl.h.
References DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), INT32, v8::internal::HeapObject::map(), OffsetOfElementAt(), and READ_INT32_FIELD.
|
inline |
Definition at line 2482 of file objects-inl.h.
References DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), INT64, v8::internal::HeapObject::map(), OffsetOfElementAt(), and READ_INT64_FIELD.
|
inline |
Definition at line 2489 of file objects-inl.h.
References DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), INT64, v8::internal::kDoubleSize, v8::internal::kInt64Size, v8::internal::HeapObject::map(), OffsetOfElementAt(), READ_DOUBLE_FIELD, and v8::internal::HeapObject::STATIC_ASSERT().
|
inline |
Definition at line 2465 of file objects-inl.h.
References DCHECK, EXTENDED_SECTION, first_extended_section_index(), FIRST_TYPE, is_extended_layout(), last_index(), LAST_TYPE, next_type(), and SMALL_SECTION.
Referenced by get_code_ptr_entry(), get_heap_ptr_entry(), get_int32_entry(), get_int64_entry(), get_int64_entry_as_double(), and set().
|
inline |
Definition at line 2380 of file objects-inl.h.
References v8::internal::BitFieldBase< T, shift, size, U >::decode(), kSmallLayout2Offset, and READ_UINT32_FIELD.
|
inline |
Definition at line 2594 of file objects-inl.h.
References CODE_PTR, DCHECK, v8::internal::BitFieldBase< T, shift, size, U >::encode(), HEAP_PTR, INT32, INT64, kFirstEntryOffset, kHeaderSize, v8::internal::kInt32Size, kSmallLayout1Offset, kSmallLayout2Offset, NO_WEAK_OBJECTS, and WRITE_UINT32_FIELD.
Referenced by v8::internal::Heap::AllocateConstantPoolArray(), and InitExtended().
|
inline |
Definition at line 2613 of file objects-inl.h.
References CODE_PTR, get_extended_section_header_offset(), HEAP_PTR, Init(), INT32, INT64, kExtendedCodePtrCountOffset, kExtendedHeapPtrCountOffset, kExtendedInt32CountOffset, kExtendedInt64CountOffset, kSmallLayout1Offset, READ_UINT32_FIELD, v8::internal::BitFieldBase< T, shift, size, U >::update(), WRITE_INT32_FIELD, and WRITE_INT_FIELD.
Referenced by v8::internal::Heap::AllocateExtendedConstantPoolArray().
|
inline |
Definition at line 2357 of file objects-inl.h.
References v8::internal::BitFieldBase< T, shift, size, U >::decode(), kSmallLayout1Offset, and READ_UINT32_FIELD.
Referenced by v8::internal::Heap::CopyConstantPoolArrayWithMap(), final_section(), first_extended_section_index(), first_index(), get_type(), length(), number_of_entries(), offset_is_type(), and size().
|
inline |
Definition at line 2410 of file objects-inl.h.
References first_index(), and number_of_entries().
Referenced by get_type(), and offset_is_type().
|
inline |
Definition at line 2647 of file objects-inl.h.
References CODE_PTR, v8::internal::BitFieldBase< T, shift, size, U >::decode(), EXTENDED_SECTION, HEAP_PTR, INT32, INT64, is_extended_layout(), kSmallLayout2Offset, number_of_entries(), and READ_UINT32_FIELD.
Referenced by v8::internal::Heap::CopyConstantPoolArray().
Definition at line 2751 of file objects.h.
References v8::internal::kInt64Size.
Definition at line 2865 of file objects.h.
References DCHECK, and v8::internal::FIRST_TYPE.
Referenced by first_index(), and get_type().
|
inline |
Definition at line 2415 of file objects-inl.h.
References CODE_PTR, DCHECK, v8::internal::BitFieldBase< T, shift, size, U >::decode(), EXTENDED_SECTION, get_extended_section_header_offset(), HEAP_PTR, INT32, INT64, is_extended_layout(), kExtendedCodePtrCountOffset, kExtendedHeapPtrCountOffset, kExtendedInt32CountOffset, kExtendedInt64CountOffset, kSmallLayout1Offset, kSmallLayout2Offset, READ_INT_FIELD, READ_UINT32_FIELD, SMALL_SECTION, and UNREACHABLE.
Referenced by ClearPtrEntries(), first_index(), last_index(), length(), and v8::internal::ConstantPoolArray::BASE_EMBEDDED::NumberOfEntries().
Definition at line 2456 of file objects-inl.h.
References EXTENDED_SECTION, first_index(), is_extended_layout(), last_index(), OffsetOfElementAt(), and SMALL_SECTION.
Referenced by set_at_offset().
Definition at line 2792 of file objects.h.
References DCHECK, v8::internal::FIRST_TYPE, and v8::internal::LAST_TYPE.
Referenced by ClearPtrEntries(), get_code_ptr_entry(), get_heap_ptr_entry(), get_int32_entry(), get_int64_entry(), get_int64_entry_as_double(), v8::internal::MarkCompactCollector::MigrateObject(), offset_is_type(), and set().
Definition at line 2819 of file objects.h.
References v8::internal::HeapObject::RawField().
Referenced by ConstantPoolIterateBody().
Definition at line 2533 of file objects-inl.h.
References CODE_PTR, DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), v8::internal::HeapObject::map(), OffsetOfElementAt(), and WRITE_FIELD.
|
inline |
Definition at line 2525 of file objects-inl.h.
References DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), INT64, v8::internal::kDoubleSize, v8::internal::kInt64Size, v8::internal::HeapObject::map(), OffsetOfElementAt(), v8::internal::HeapObject::STATIC_ASSERT(), and WRITE_DOUBLE_FIELD.
|
inline |
Definition at line 2549 of file objects-inl.h.
References DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), INT32, v8::internal::HeapObject::map(), OffsetOfElementAt(), and WRITE_INT32_FIELD.
|
inline |
Definition at line 2518 of file objects-inl.h.
References DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), INT64, v8::internal::HeapObject::map(), OffsetOfElementAt(), and WRITE_INT64_FIELD.
Definition at line 2540 of file objects-inl.h.
References DCHECK, get_type(), v8::internal::HeapObject::GetHeap(), HEAP_PTR, v8::internal::HeapObject::map(), OffsetOfElementAt(), WRITE_BARRIER, and WRITE_FIELD.
Definition at line 2577 of file objects-inl.h.
References CODE_PTR, DCHECK, v8::internal::HeapObject::GetHeap(), v8::internal::HeapObject::map(), offset_is_type(), WRITE_BARRIER, and WRITE_FIELD.
|
inline |
Definition at line 2570 of file objects-inl.h.
References DCHECK, v8::internal::HeapObject::GetHeap(), INT64, v8::internal::HeapObject::map(), offset_is_type(), and WRITE_DOUBLE_FIELD.
|
inline |
Definition at line 2556 of file objects-inl.h.
References DCHECK, v8::internal::HeapObject::GetHeap(), INT32, v8::internal::HeapObject::map(), offset_is_type(), and WRITE_INT32_FIELD.
|
inline |
Definition at line 2563 of file objects-inl.h.
References DCHECK, v8::internal::HeapObject::GetHeap(), INT64, v8::internal::HeapObject::map(), offset_is_type(), and WRITE_INT64_FIELD.
Definition at line 2585 of file objects-inl.h.
References DCHECK, v8::internal::HeapObject::GetHeap(), HEAP_PTR, v8::internal::HeapObject::map(), offset_is_type(), WRITE_BARRIER, and WRITE_FIELD.
|
inline |
Definition at line 2386 of file objects-inl.h.
References kSmallLayout2Offset, READ_UINT32_FIELD, v8::internal::BitFieldBase< T, shift, size, U >::update(), and WRITE_INT32_FIELD.
|
inline |
Definition at line 2636 of file objects-inl.h.
References EXTENDED_SECTION, is_extended_layout(), SizeFor(), SizeForExtended(), and SMALL_SECTION.
Referenced by v8::internal::Heap::CopyConstantPoolArrayWithMap().
|
inlinestatic |
Definition at line 2755 of file objects.h.
References v8::internal::kInt32Size, v8::internal::kInt64Size, v8::internal::kPointerSize, v8::internal::RoundUp(), and size.
Referenced by v8::internal::Heap::AllocateConstantPoolArray(), v8::internal::Heap::AllocateEmptyConstantPoolArray(), get_extended_section_header_offset(), and size().
|
inlinestatic |
Definition at line 2764 of file objects.h.
References v8::internal::kInt32Size, v8::internal::kInt64Size, v8::internal::kPointerSize, v8::internal::RoundUp(), and size.
Referenced by v8::internal::Heap::AllocateExtendedConstantPoolArray(), and size().
|
static |
Definition at line 2846 of file objects.h.
Referenced by InitExtended(), and number_of_entries().
|
static |
|
static |
Definition at line 2848 of file objects.h.
Referenced by InitExtended(), and number_of_entries().
|
static |
Definition at line 2850 of file objects.h.
Referenced by InitExtended(), and number_of_entries().
|
static |
Definition at line 2845 of file objects.h.
Referenced by InitExtended(), and number_of_entries().
|
static |
Definition at line 2827 of file objects.h.
Referenced by v8::internal::Heap::CopyConstantPoolArrayWithMap(), and Init().
|
static |
|
static |
Definition at line 2830 of file objects.h.
Referenced by v8::internal::Heap::AllocateConstantPoolArray(), and v8::internal::Heap::AllocateExtendedConstantPoolArray().
|
static |
Definition at line 2824 of file objects.h.
Referenced by Init(), InitExtended(), is_extended_layout(), and number_of_entries().
|
static |
Definition at line 2825 of file objects.h.
Referenced by first_extended_section_index(), get_weak_object_state(), Init(), length(), number_of_entries(), and set_weak_object_state().
|
static |