| 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 2147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2158 return JSMessageObject::kSize; | 2158 return JSMessageObject::kSize; |
| 2159 case JS_ARGUMENTS_TYPE: | 2159 case JS_ARGUMENTS_TYPE: |
| 2160 return JSArgumentsObject::kHeaderSize; | 2160 return JSArgumentsObject::kHeaderSize; |
| 2161 case JS_ERROR_TYPE: | 2161 case JS_ERROR_TYPE: |
| 2162 return JSObject::kHeaderSize; | 2162 return JSObject::kHeaderSize; |
| 2163 case JS_STRING_ITERATOR_TYPE: | 2163 case JS_STRING_ITERATOR_TYPE: |
| 2164 return JSStringIterator::kSize; | 2164 return JSStringIterator::kSize; |
| 2165 case JS_MODULE_NAMESPACE_TYPE: | 2165 case JS_MODULE_NAMESPACE_TYPE: |
| 2166 return JSModuleNamespace::kSize; | 2166 return JSModuleNamespace::kSize; |
| 2167 default: | 2167 default: |
| 2168 if (type >= FIRST_ARRAY_ITERATOR_TYPE && |
| 2169 type <= LAST_ARRAY_ITERATOR_TYPE) { |
| 2170 return JSArrayIterator::kSize; |
| 2171 } |
| 2168 UNREACHABLE(); | 2172 UNREACHABLE(); |
| 2169 return 0; | 2173 return 0; |
| 2170 } | 2174 } |
| 2171 } | 2175 } |
| 2172 | 2176 |
| 2173 | 2177 |
| 2174 int JSObject::GetInternalFieldCount(Map* map) { | 2178 int JSObject::GetInternalFieldCount(Map* map) { |
| 2175 int instance_size = map->instance_size(); | 2179 int instance_size = map->instance_size(); |
| 2176 if (instance_size == kVariableSizeSentinel) return 0; | 2180 if (instance_size == kVariableSizeSentinel) return 0; |
| 2177 InstanceType instance_type = map->instance_type(); | 2181 InstanceType instance_type = map->instance_type(); |
| (...skipping 6253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8431 #undef WRITE_INT64_FIELD | 8435 #undef WRITE_INT64_FIELD |
| 8432 #undef READ_BYTE_FIELD | 8436 #undef READ_BYTE_FIELD |
| 8433 #undef WRITE_BYTE_FIELD | 8437 #undef WRITE_BYTE_FIELD |
| 8434 #undef NOBARRIER_READ_BYTE_FIELD | 8438 #undef NOBARRIER_READ_BYTE_FIELD |
| 8435 #undef NOBARRIER_WRITE_BYTE_FIELD | 8439 #undef NOBARRIER_WRITE_BYTE_FIELD |
| 8436 | 8440 |
| 8437 } // namespace internal | 8441 } // namespace internal |
| 8438 } // namespace v8 | 8442 } // namespace v8 |
| 8439 | 8443 |
| 8440 #endif // V8_OBJECTS_INL_H_ | 8444 #endif // V8_OBJECTS_INL_H_ |
| OLD | NEW |