OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 // | 4 // |
5 // Review notes: | 5 // Review notes: |
6 // | 6 // |
7 // - The use of macros in these inline functions may seem superfluous | 7 // - The use of macros in these inline functions may seem superfluous |
8 // but it is absolutely needed to make sure gcc generates optimal | 8 // but it is absolutely needed to make sure gcc generates optimal |
9 // code. gcc is not happy when attempting to inline too deep. | 9 // code. gcc is not happy when attempting to inline too deep. |
10 // | 10 // |
(...skipping 4037 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4048 | 4048 |
4049 int BytecodeArray::parameter_count() const { | 4049 int BytecodeArray::parameter_count() const { |
4050 // Parameter count is stored as the size on stack of the parameters to allow | 4050 // Parameter count is stored as the size on stack of the parameters to allow |
4051 // it to be used directly by generated code. | 4051 // it to be used directly by generated code. |
4052 return READ_INT_FIELD(this, kParameterSizeOffset) >> kPointerSizeLog2; | 4052 return READ_INT_FIELD(this, kParameterSizeOffset) >> kPointerSizeLog2; |
4053 } | 4053 } |
4054 | 4054 |
4055 | 4055 |
4056 ACCESSORS(BytecodeArray, constant_pool, FixedArray, kConstantPoolOffset) | 4056 ACCESSORS(BytecodeArray, constant_pool, FixedArray, kConstantPoolOffset) |
4057 ACCESSORS(BytecodeArray, handler_table, FixedArray, kHandlerTableOffset) | 4057 ACCESSORS(BytecodeArray, handler_table, FixedArray, kHandlerTableOffset) |
4058 ACCESSORS(BytecodeArray, source_position_table, ByteArray, | 4058 ACCESSORS(BytecodeArray, source_position_table, FixedArray, |
4059 kSourcePositionTableOffset) | 4059 kSourcePositionTableOffset) |
4060 | 4060 |
| 4061 |
4061 Address BytecodeArray::GetFirstBytecodeAddress() { | 4062 Address BytecodeArray::GetFirstBytecodeAddress() { |
4062 return reinterpret_cast<Address>(this) - kHeapObjectTag + kHeaderSize; | 4063 return reinterpret_cast<Address>(this) - kHeapObjectTag + kHeaderSize; |
4063 } | 4064 } |
4064 | 4065 |
4065 | 4066 |
4066 int BytecodeArray::BytecodeArraySize() { return SizeFor(this->length()); } | 4067 int BytecodeArray::BytecodeArraySize() { return SizeFor(this->length()); } |
4067 | 4068 |
4068 | 4069 |
4069 ACCESSORS(FixedTypedArrayBase, base_pointer, Object, kBasePointerOffset) | 4070 ACCESSORS(FixedTypedArrayBase, base_pointer, Object, kBasePointerOffset) |
4070 | 4071 |
(...skipping 3772 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7843 #undef WRITE_INT64_FIELD | 7844 #undef WRITE_INT64_FIELD |
7844 #undef READ_BYTE_FIELD | 7845 #undef READ_BYTE_FIELD |
7845 #undef WRITE_BYTE_FIELD | 7846 #undef WRITE_BYTE_FIELD |
7846 #undef NOBARRIER_READ_BYTE_FIELD | 7847 #undef NOBARRIER_READ_BYTE_FIELD |
7847 #undef NOBARRIER_WRITE_BYTE_FIELD | 7848 #undef NOBARRIER_WRITE_BYTE_FIELD |
7848 | 7849 |
7849 } // namespace internal | 7850 } // namespace internal |
7850 } // namespace v8 | 7851 } // namespace v8 |
7851 | 7852 |
7852 #endif // V8_OBJECTS_INL_H_ | 7853 #endif // V8_OBJECTS_INL_H_ |
OLD | NEW |