| Index: src/objects-inl.h
|
| diff --git a/src/objects-inl.h b/src/objects-inl.h
|
| index 3d82bf8205a895693d45fc1d1a27e3118c8959ec..3f44c718ab6adc71a205faf1c49af7a389c99230 100644
|
| --- a/src/objects-inl.h
|
| +++ b/src/objects-inl.h
|
| @@ -709,6 +709,8 @@ bool HeapObject::IsJSCollection() const { return IsJSMap() || IsJSSet(); }
|
|
|
| bool HeapObject::IsDescriptorArray() const { return IsFixedArray(); }
|
|
|
| +bool HeapObject::IsFrameArray() const { return IsFixedArray(); }
|
| +
|
| bool HeapObject::IsArrayList() const { return IsFixedArray(); }
|
|
|
| bool Object::IsLayoutDescriptor() const {
|
| @@ -2610,6 +2612,38 @@ Object** FixedArray::RawFieldOfElementAt(int index) {
|
| return HeapObject::RawField(this, OffsetOfElementAt(index));
|
| }
|
|
|
| +#define DEFINE_FRAME_ARRAY_ACCESSORS(name, type) \
|
| + type* FrameArray::name(int frame_ix) const { \
|
| + Object* obj = \
|
| + get(kFirstIndex + frame_ix * kElementsPerFrame + k##name##Offset); \
|
| + return type::cast(obj); \
|
| + } \
|
| + \
|
| + void FrameArray::Set##name(int frame_ix, type* value) { \
|
| + set(kFirstIndex + frame_ix * kElementsPerFrame + k##name##Offset, value); \
|
| + }
|
| +FRAME_ARRAY_FIELD_LIST(DEFINE_FRAME_ARRAY_ACCESSORS)
|
| +#undef DEFINE_FRAME_ARRAY_ACCESSORS
|
| +
|
| +int FrameArray::SloppyFrameCount() const {
|
| + return Smi::cast(get(kSloppyFramesIndex))->value();
|
| +}
|
| +
|
| +void FrameArray::SetSloppyFrameCount(int count) {
|
| + return set(kSloppyFramesIndex, Smi::FromInt(count));
|
| +}
|
| +
|
| +bool FrameArray::IsWasmFrame(int frame_ix) const {
|
| + Object* obj = get(kFirstIndex + frame_ix * kElementsPerFrame +
|
| + kWasmFunctionIndexOffset);
|
| + return obj->IsSmi();
|
| +}
|
| +
|
| +int FrameArray::FrameCount() const {
|
| + const int frame_count = Smi::cast(get(kFrameCountIndex))->value();
|
| + DCHECK_LE(0, frame_count);
|
| + return frame_count;
|
| +}
|
|
|
| bool DescriptorArray::IsEmpty() {
|
| DCHECK(length() >= kFirstIndex ||
|
| @@ -3223,6 +3257,7 @@ CAST_ACCESSOR(FixedDoubleArray)
|
| CAST_ACCESSOR(FixedTypedArrayBase)
|
| CAST_ACCESSOR(Float32x4)
|
| CAST_ACCESSOR(Foreign)
|
| +CAST_ACCESSOR(FrameArray)
|
| CAST_ACCESSOR(GlobalDictionary)
|
| CAST_ACCESSOR(HandlerTable)
|
| CAST_ACCESSOR(HeapObject)
|
|
|