v8
3.14.5(node0.10.28)
V8 is Google's open source JavaScript engine
|
#include <objects.h>
Data Structures | |
class | WhitenessWitness |
Public Member Functions | |
bool | IsEmpty () |
int | number_of_descriptors () |
int | number_of_descriptors_storage () |
int | NumberOfSlackDescriptors () |
void | SetNumberOfDescriptors (int number_of_descriptors) |
int | number_of_entries () |
bool | HasEnumCache () |
void | CopyEnumCacheFrom (DescriptorArray *array) |
FixedArray * | GetEnumCache () |
bool | HasEnumIndicesCache () |
FixedArray * | GetEnumIndicesCache () |
Object ** | GetEnumCacheSlot () |
void | ClearEnumCache () |
void | SetEnumCache (FixedArray *bridge_storage, FixedArray *new_cache, Object *new_index_cache) |
String * | GetKey (int descriptor_number) |
Object ** | GetKeySlot (int descriptor_number) |
Object * | GetValue (int descriptor_number) |
Object ** | GetValueSlot (int descriptor_number) |
PropertyDetails | GetDetails (int descriptor_number) |
PropertyType | GetType (int descriptor_number) |
int | GetFieldIndex (int descriptor_number) |
JSFunction * | GetConstantFunction (int descriptor_number) |
Object * | GetCallbacksObject (int descriptor_number) |
AccessorDescriptor * | GetCallbacks (int descriptor_number) |
String * | GetSortedKey (int descriptor_number) |
int | GetSortedKeyIndex (int descriptor_number) |
void | SetSortedKey (int pointer, int descriptor_number) |
void | Get (int descriptor_number, Descriptor *desc) |
void | Set (int descriptor_number, Descriptor *desc, const WhitenessWitness &) |
void | Set (int descriptor_number, Descriptor *desc) |
void | Append (Descriptor *desc, const WhitenessWitness &) |
void | Append (Descriptor *desc) |
void | CopyFrom (int dst_index, DescriptorArray *src, int src_index, const WhitenessWitness &) |
MUST_USE_RESULT MaybeObject * | CopyUpTo (int enumeration_index) |
void | Sort () |
INLINE (int Search(String *name, int number_of_own_descriptors)) | |
INLINE (int SearchWithCache(String *name, Map *map)) | |
Public Member Functions inherited from FixedArray | |
Object * | get (int index) |
void | set (int index, Object *value) |
bool | is_the_hole (int index) |
void | set (int index, Smi *value) |
void | set (int index, Object *value, WriteBarrierMode mode) |
void | set_undefined (int index) |
void | set_undefined (Heap *heap, int index) |
void | set_null (int index) |
void | set_null (Heap *heap, int index) |
void | set_the_hole (int index) |
void | set_unchecked (int index, Smi *value) |
void | set_null_unchecked (Heap *heap, int index) |
void | set_unchecked (Heap *heap, int index, Object *value, WriteBarrierMode mode) |
Object ** | data_start () |
Object ** | GetFirstElementAddress () |
bool | ContainsOnlySmisOrHoles () |
MUST_USE_RESULT MaybeObject * | Copy () |
MUST_USE_RESULT MaybeObject * | CopySize (int new_length) |
MUST_USE_RESULT MaybeObject * | AddKeysFromJSArray (JSArray *array) |
MUST_USE_RESULT MaybeObject * | UnionOfKeys (FixedArray *other) |
void | CopyTo (int pos, FixedArray *dest, int dest_pos, int len) |
void | SwapPairs (FixedArray *numbers, int i, int j) |
void | SortPairs (FixedArray *numbers, uint32_t len) |
Public Member Functions inherited from FixedArrayBase | |
int | length () |
void | set_length (int value) |
Public Member Functions inherited from HeapObject | |
Map * | map () |
void | set_map (Map *value) |
void | set_map_no_write_barrier (Map *value) |
MapWord | map_word () |
void | set_map_word (MapWord map_word) |
Heap * | GetHeap () |
Isolate * | GetIsolate () |
Address | address () |
void | Iterate (ObjectVisitor *v) |
void | IterateBody (InstanceType type, int object_size, ObjectVisitor *v) |
int | Size () |
int | SizeFromMap (Map *map) |
WriteBarrierMode | GetWriteBarrierMode (const AssertNoAllocation &) |
void | HeapObjectShortPrint (StringStream *accumulator) |
STATIC_CHECK (kMapOffset==Internals::kHeapObjectMapOffset) | |
Public Member Functions inherited from Object | |
bool | IsObject () |
bool | IsFixedArrayBase () |
bool | IsInstanceOf (FunctionTemplateInfo *type) |
bool | IsStruct () |
INLINE (bool IsSpecObject()) | |
INLINE (bool IsSpecFunction()) | |
INLINE (bool IsUndefined()) | |
INLINE (bool IsNull()) | |
INLINE (bool IsTheHole()) | |
INLINE (bool IsTrue()) | |
INLINE (bool IsFalse()) | |
bool | IsArgumentsMarker () |
bool | NonFailureIsHeapObject () |
bool | IsFiller () |
double | Number () |
bool | IsNaN () |
bool | HasValidElements () |
bool | HasSpecificClassOf (String *name) |
MUST_USE_RESULT MaybeObject * | ToObject () |
Object * | ToBoolean () |
MUST_USE_RESULT MaybeObject * | ToObject (Context *native_context) |
MUST_USE_RESULT MaybeObject * | ToSmi () |
void | Lookup (String *name, LookupResult *result) |
MUST_USE_RESULT MaybeObject * | GetProperty (String *key) |
MUST_USE_RESULT MaybeObject * | GetProperty (String *key, PropertyAttributes *attributes) |
MUST_USE_RESULT MaybeObject * | GetPropertyWithReceiver (Object *receiver, String *key, PropertyAttributes *attributes) |
MUST_USE_RESULT MaybeObject * | GetProperty (Object *receiver, LookupResult *result, String *key, PropertyAttributes *attributes) |
MUST_USE_RESULT MaybeObject * | GetPropertyWithDefinedGetter (Object *receiver, JSReceiver *getter) |
MUST_USE_RESULT MaybeObject * | GetElement (uint32_t index) |
Object * | GetElementNoExceptionThrown (uint32_t index) |
MUST_USE_RESULT MaybeObject * | GetElementWithReceiver (Object *receiver, uint32_t index) |
Object * | GetPrototype () |
MUST_USE_RESULT MaybeObject * | GetHash (CreationFlag flag) |
bool | SameValue (Object *other) |
bool | ToArrayIndex (uint32_t *index) |
bool | IsStringObjectWithCharacterAt (uint32_t index) |
void | VerifyApiCallResultType () |
void | ShortPrint () |
void | ShortPrint (FILE *out) |
void | ShortPrint (StringStream *accumulator) |
Static Public Member Functions | |
static MUST_USE_RESULT MaybeObject * | Allocate (int number_of_descriptors, int slack=0) |
static DescriptorArray * | cast (Object *obj) |
static int | LengthFor (int number_of_descriptors) |
Static Public Member Functions inherited from FixedArray | |
static int | SizeFor (int length) |
static int | OffsetOfElementAt (int index) |
static FixedArray * | cast (Object *obj) |
Static Public Member Functions inherited from FixedArrayBase | |
static FixedArrayBase * | cast (Object *object) |
Static Public Member Functions inherited from HeapObject | |
static HeapObject * | FromAddress (Address address) |
static Object ** | RawField (HeapObject *obj, int offset) |
static HeapObject * | cast (Object *obj) |
Static Public Member Functions inherited from Object | |
static Handle< Object > | GetProperty (Handle< Object > object, Handle< Object > receiver, LookupResult *result, Handle< String > key, PropertyAttributes *attributes) |
static Handle< Object > | GetElement (Handle< Object > object, uint32_t index) |
static Object * | cast (Object *value) |
Static Public Attributes | |
static const int | kNotFound = -1 |
static const int | kDescriptorLengthIndex = 0 |
static const int | kEnumCacheIndex = 1 |
static const int | kFirstIndex = 2 |
static const int | kEnumCacheBridgeLength = 2 |
static const int | kEnumCacheBridgeCacheIndex = 0 |
static const int | kEnumCacheBridgeIndicesCacheIndex = 1 |
static const int | kDescriptorLengthOffset = FixedArray::kHeaderSize |
static const int | kEnumCacheOffset = kDescriptorLengthOffset + kPointerSize |
static const int | kFirstOffset = kEnumCacheOffset + kPointerSize |
static const int | kEnumCacheBridgeCacheOffset = FixedArray::kHeaderSize |
static const int | kDescriptorKey = 0 |
static const int | kDescriptorDetails = 1 |
static const int | kDescriptorValue = 2 |
static const int | kDescriptorSize = 3 |
static const int | kMaxNumberOfDescriptors = 1024 + 512 |
Static Public Attributes inherited from FixedArray | |
static const int | kMaxSize = 128 * MB * kPointerSize |
static const int | kMaxLength = (kMaxSize - kHeaderSize) / kPointerSize |
Static Public Attributes inherited from FixedArrayBase | |
static const int | kLengthOffset = HeapObject::kHeaderSize |
static const int | kHeaderSize = kLengthOffset + kPointerSize |
Static Public Attributes inherited from HeapObject | |
static const int | kMapOffset = Object::kHeaderSize |
static const int | kHeaderSize = kMapOffset + kPointerSize |
Static Public Attributes inherited from Object | |
static const int | kHeaderSize = 0 |
Additional Inherited Members | |
Protected Member Functions inherited from HeapObject | |
void | IteratePointers (ObjectVisitor *v, int start, int end) |
void | IteratePointer (ObjectVisitor *v, int offset) |
Static Protected Member Functions inherited from FixedArray | |
static void | NoWriteBarrierSet (FixedArray *array, int index, Object *value) |
static void | NoIncrementalWriteBarrierSet (FixedArray *array, int index, Object *value) |
|
static |
Definition at line 6032 of file objects.cc.
References Heap::AllocateFixedArray(), Smi::FromInt(), and FixedArray::set().
Referenced by Heap::AllocateInitialMap(), Map::CopyAddDescriptor(), Map::CopyReplaceDescriptor(), Factory::NewDescriptorArray(), Map::ShareDescriptor(), and StringDictionary::TransformPropertiesToFastFor().
|
inline |
Definition at line 2205 of file objects-inl.h.
References DescriptorArray::GetSortedKey(), DescriptorArray::GetSortedKeyIndex(), String::Hash(), DescriptorArray::number_of_descriptors(), DescriptorArray::Set(), DescriptorArray::SetNumberOfDescriptors(), and DescriptorArray::SetSortedKey().
Referenced by Map::AppendDescriptor(), Map::CopyAddDescriptor(), and Map::ShareDescriptor().
|
inline |
Definition at line 2227 of file objects-inl.h.
References DescriptorArray::GetSortedKey(), DescriptorArray::GetSortedKeyIndex(), String::Hash(), DescriptorArray::number_of_descriptors(), DescriptorArray::Set(), DescriptorArray::SetNumberOfDescriptors(), and DescriptorArray::SetSortedKey().
|
inlinestatic |
void ClearEnumCache | ( | ) |
Definition at line 6048 of file objects.cc.
References Smi::FromInt().
|
inline |
Definition at line 2524 of file objects.h.
References FixedArray::get().
Referenced by Map::ShareDescriptor().
void CopyFrom | ( | int | dst_index, |
DescriptorArray * | src, | ||
int | src_index, | ||
const WhitenessWitness & | witness | ||
) |
Definition at line 6068 of file objects.cc.
References DescriptorArray::GetDetails(), DescriptorArray::GetKey(), and DescriptorArray::GetValue().
Referenced by Map::CopyAddDescriptor(), Map::CopyReplaceDescriptor(), DescriptorArray::CopyUpTo(), and Map::ShareDescriptor().
MaybeObject * CopyUpTo | ( | int | enumeration_index | ) |
Definition at line 5203 of file objects.cc.
References DescriptorArray::CopyFrom(), HeapObject::GetHeap(), and DescriptorArray::Sort().
Referenced by Map::Copy(), and Map::CopyWithPreallocatedFieldDescriptors().
|
inline |
Definition at line 2164 of file objects-inl.h.
References DescriptorArray::GetDetails(), DescriptorArray::GetKey(), and DescriptorArray::GetValue().
|
inline |
Definition at line 2157 of file objects-inl.h.
References ASSERT, v8::internal::CALLBACKS, Foreign::cast(), Foreign::foreign_address(), DescriptorArray::GetCallbacksObject(), and DescriptorArray::GetType().
Referenced by Map::FindAccessor().
|
inline |
Definition at line 2151 of file objects-inl.h.
References ASSERT, v8::internal::CALLBACKS, DescriptorArray::GetType(), and DescriptorArray::GetValue().
Referenced by Heap::AllocateGlobalObject(), DescriptorArray::GetCallbacks(), and JSObject::NormalizeProperties().
|
inline |
Definition at line 2146 of file objects-inl.h.
References JSFunction::cast(), and DescriptorArray::GetValue().
Referenced by JSObject::NormalizeProperties(), and JSObject::SlowReverseLookup().
|
inline |
Definition at line 2129 of file objects-inl.h.
References ASSERT, Smi::cast(), and DescriptorArray::number_of_descriptors().
Referenced by Heap::AllocateGlobalObject(), DescriptorArray::CopyFrom(), Map::CopyReplaceDescriptor(), DescriptorArray::Get(), DescriptorArray::GetSortedKeyIndex(), TransitionArray::GetTargetDetails(), DescriptorArray::GetType(), Map::InitializeDescriptors(), Map::LookupDescriptor(), JSObject::NormalizeProperties(), Map::NumberOfDescribedProperties(), StringStream::PrintUsingMap(), v8::internal::RUNTIME_FUNCTION(), JSObject::SetLocalPropertyIgnoreAttributes(), JSObject::SetPropertyForResult(), and DescriptorArray::SetSortedKey().
|
inline |
Definition at line 2528 of file objects.h.
References ASSERT, FixedArray::cast(), and FixedArray::get().
Referenced by v8::internal::GetEnumPropertyKeys().
|
inline |
Definition at line 2548 of file objects.h.
References ASSERT, and HeapObject::RawField().
|
inline |
Definition at line 2542 of file objects.h.
References ASSERT, FixedArray::cast(), and FixedArray::get().
|
inline |
Definition at line 2141 of file objects-inl.h.
References DescriptorArray::GetValue().
Referenced by Map::NextFreePropertyIndex(), JSObject::NormalizeProperties(), StringStream::PrintUsingMap(), Map::PropertyIndexFor(), JSObject::SetLocalPropertyIgnoreAttributes(), JSObject::SetPropertyForResult(), JSObject::SlowReverseLookup(), and TEST().
|
inline |
Definition at line 2093 of file objects-inl.h.
References ASSERT, String::cast(), and DescriptorArray::number_of_descriptors().
Referenced by Heap::AllocateGlobalObject(), DescriptorArray::CopyFrom(), Map::CopyReplaceDescriptor(), Map::FindAccessor(), DescriptorArray::Get(), JSObject::GetLocalPropertyNames(), DescriptorArray::GetSortedKey(), JSObject::NormalizeProperties(), StringStream::PrintUsingMap(), Map::PropertyIndexFor(), and JSObject::SlowReverseLookup().
|
inline |
Definition at line 2085 of file objects-inl.h.
References ASSERT, DescriptorArray::number_of_descriptors(), FixedArray::OffsetOfElementAt(), and HeapObject::RawField().
|
inline |
Definition at line 2104 of file objects-inl.h.
References DescriptorArray::GetKey(), and DescriptorArray::GetSortedKeyIndex().
Referenced by DescriptorArray::Append().
|
inline |
Definition at line 2099 of file objects-inl.h.
References DescriptorArray::GetDetails().
Referenced by DescriptorArray::Append(), and DescriptorArray::GetSortedKey().
|
inline |
Definition at line 2136 of file objects-inl.h.
References DescriptorArray::GetDetails().
Referenced by Map::FindAccessor(), DescriptorArray::GetCallbacks(), DescriptorArray::GetCallbacksObject(), Map::NextFreePropertyIndex(), and JSObject::SlowReverseLookup().
|
inline |
Definition at line 2123 of file objects-inl.h.
References ASSERT, and DescriptorArray::number_of_descriptors().
Referenced by DescriptorArray::CopyFrom(), DescriptorArray::Get(), DescriptorArray::GetCallbacksObject(), DescriptorArray::GetConstantFunction(), DescriptorArray::GetFieldIndex(), v8::internal::RUNTIME_FUNCTION(), and JSObject::SetPropertyForResult().
|
inline |
Definition at line 2115 of file objects-inl.h.
References ASSERT, DescriptorArray::number_of_descriptors(), FixedArray::OffsetOfElementAt(), and HeapObject::RawField().
|
inline |
Definition at line 2520 of file objects.h.
Referenced by Map::ShareDescriptor().
|
inline |
Definition at line 2534 of file objects.h.
References FixedArray::cast(), and FixedArray::get().
INLINE | ( | int | SearchString *name, int number_of_own_descriptors | ) |
INLINE | ( | int | SearchWithCacheString *name, Map *map | ) |
|
inline |
Definition at line 1939 of file objects-inl.h.
References ASSERT, HEAP, DescriptorArray::kFirstIndex, and FixedArrayBase::length().
|
inlinestatic |
|
inline |
Definition at line 2502 of file objects.h.
References ASSERT, Smi::cast(), and Smi::value().
Referenced by Heap::AllocateGlobalObject(), DescriptorArray::Append(), Map::AppendDescriptor(), Map::ClearNonLiveTransitions(), Map::CopyAddDescriptor(), Map::CopyReplaceDescriptors(), DescriptorArray::GetDetails(), DescriptorArray::GetKey(), DescriptorArray::GetKeySlot(), DescriptorArray::GetValue(), DescriptorArray::GetValueSlot(), Map::InitializeDescriptors(), Map::NumberOfDescribedProperties(), StringStream::PrintUsingMap(), DescriptorArray::Set(), and Map::ShareDescriptor().
|
inline |
Definition at line 2513 of file objects.h.
Referenced by Map::ShareDescriptor().
|
inline |
Definition at line 2171 of file objects-inl.h.
References ASSERT, FixedArray::NoIncrementalWriteBarrierSet(), and DescriptorArray::number_of_descriptors().
Referenced by Heap::AllocateInitialMap(), DescriptorArray::Append(), Map::CopyAddDescriptor(), Map::CopyReplaceDescriptor(), and StringDictionary::TransformPropertiesToFastFor().
|
inline |
Definition at line 2192 of file objects-inl.h.
References ASSERT, DescriptorArray::number_of_descriptors(), and FixedArray::set().
void SetEnumCache | ( | FixedArray * | bridge_storage, |
FixedArray * | new_cache, | ||
Object * | new_index_cache | ||
) |
Definition at line 6053 of file objects.cc.
References ASSERT, FixedArray::cast(), and FixedArrayBase::length().
Referenced by v8::internal::GetEnumPropertyKeys().
|
inline |
Definition at line 1946 of file objects-inl.h.
References Smi::FromInt(), DescriptorArray::kDescriptorLengthOffset, and WRITE_FIELD.
Referenced by DescriptorArray::Append(), and Map::CopyAddDescriptor().
|
inline |
Definition at line 2109 of file objects-inl.h.
References DescriptorArray::GetDetails(), and FixedArray::set().
Referenced by DescriptorArray::Append().
void Sort | ( | ) |
Definition at line 6083 of file objects.cc.
References ASSERT.
Referenced by Heap::AllocateInitialMap(), Map::CopyAddDescriptor(), Map::CopyReplaceDescriptor(), DescriptorArray::CopyUpTo(), and StringDictionary::TransformPropertiesToFastFor().
|
static |
Definition at line 2631 of file objects.h.
Referenced by DescriptorArray::SetNumberOfDescriptors().
|
static |
|
static |
Definition at line 2626 of file objects.h.
Referenced by v8::internal::GetEnumPropertyKeys().
|
static |
|
static |
Definition at line 2623 of file objects.h.
Referenced by DescriptorArray::IsEmpty().
|
static |
Definition at line 2633 of file objects.h.
Referenced by ConsString::first(), ConsString::set_first(), and ConsString::unchecked_first().
|
static |
Definition at line 2665 of file objects.h.
Referenced by JSObject::AddProperty(), Map::InitializeDescriptors(), and StringDictionary::TransformPropertiesToFastFor().
|
static |
Definition at line 2619 of file objects.h.
Referenced by JSObject::AddFastProperty(), Map::AppendCallbackDescriptors(), Map::CopyInsertDescriptor(), HashTable< Shape, Key >::FindEntry(), Map::LookupDescriptor(), and v8::internal::RUNTIME_FUNCTION().