38 static MaybeObject* AllocateRaw(
int length) {
39 Heap* heap = Isolate::Current()->heap();
43 MaybeObject* maybe_array = heap->AllocateFixedArray(length);
44 if (!maybe_array->To(&array))
return maybe_array;
51 MaybeObject* maybe_array = AllocateRaw(ToKeyIndex(number_of_transitions));
52 if (!maybe_array->To(&array))
return maybe_array;
60 int origin_transition,
61 int target_transition) {
62 NoIncrementalWriteBarrierSet(target_transition,
63 origin->
GetKey(origin_transition),
68 static bool InsertionPointFound(
String* key1,
String* key2) {
78 MaybeObject* maybe_result;
82 if (!maybe_result->To(&result))
return maybe_result;
86 if (!maybe_result->To(&result))
return maybe_result;
87 result->NoIncrementalWriteBarrierSet(0, key, target);
98 MaybeObject* maybe_result =
Allocate(nof);
99 if (!maybe_result->To(&result))
return maybe_result;
116 int insertion_index = this->
Search(name);
117 if (insertion_index ==
kNotFound) ++new_size;
119 MaybeObject* maybe_array;
121 if (!maybe_array->To(&result))
return maybe_array;
133 if (i != insertion_index) {
137 result->NoIncrementalWriteBarrierSet(insertion_index, name, target);
143 if (InsertionPointFound(
GetKey(insertion_index), name))
break;
145 this, insertion_index, insertion_index);
148 result->NoIncrementalWriteBarrierSet(insertion_index, name, target);
152 this, insertion_index, insertion_index + 1);
Map * elements_transition()
void set(int index, Object *value)
static MUST_USE_RESULT MaybeObject * Allocate(int number_of_transitions)
static Smi * FromInt(int value)
static const int kPrototypeTransitionsIndex
bool IsFullTransitionArray()
#define ASSERT(condition)
static const int kElementsTransitionIndex
void NoIncrementalWriteBarrierCopyFrom(TransitionArray *origin, int origin_transition, int target_transition)
static const int kSimpleTransitionTarget
static const int kNotFound
bool HasPrototypeTransitions()
int number_of_transitions()
void SetPrototypeTransitions(FixedArray *prototype_transitions, WriteBarrierMode mode=UPDATE_WRITE_BARRIER)
MUST_USE_RESULT MaybeObject * CopyInsert(String *name, Map *target)
static const int kSimpleTransitionIndex
String * GetKey(int transition_number)
static MUST_USE_RESULT MaybeObject * NewWith(SimpleTransitionFlag flag, String *key, Map *target, Object *back_pointer)
bool HasElementsTransition()
static const int kSimpleTransitionSize
Map * GetTarget(int transition_number)
void set_back_pointer_storage(Object *back_pointer, WriteBarrierMode mode=UPDATE_WRITE_BARRIER)
FixedArray * GetPrototypeTransitions()
Object * back_pointer_storage()
void set_elements_transition(Map *target, WriteBarrierMode mode=UPDATE_WRITE_BARRIER)
MUST_USE_RESULT MaybeObject * ExtendToFullTransitionArray()
kPropertyAccessorsOffset kNamedPropertyHandlerOffset kInstanceTemplateOffset kAccessCheckInfoOffset kEvalFrominstructionsOffsetOffset kInstanceClassNameOffset flag