| 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 5649 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5660 WRITE_FIELD(this, kScopeInfoOffset, reinterpret_cast<Object*>(value)); | 5660 WRITE_FIELD(this, kScopeInfoOffset, reinterpret_cast<Object*>(value)); |
| 5661 CONDITIONAL_WRITE_BARRIER(GetHeap(), | 5661 CONDITIONAL_WRITE_BARRIER(GetHeap(), |
| 5662 this, | 5662 this, |
| 5663 kScopeInfoOffset, | 5663 kScopeInfoOffset, |
| 5664 reinterpret_cast<Object*>(value), | 5664 reinterpret_cast<Object*>(value), |
| 5665 mode); | 5665 mode); |
| 5666 } | 5666 } |
| 5667 | 5667 |
| 5668 | 5668 |
| 5669 bool SharedFunctionInfo::is_compiled() { | 5669 bool SharedFunctionInfo::is_compiled() { |
| 5670 return code() != | 5670 return code() != GetIsolate()->builtins()->builtin(Builtins::kCompileLazy); |
| 5671 GetIsolate()->builtins()->builtin(Builtins::kCompileUnoptimized); | |
| 5672 } | 5671 } |
| 5673 | 5672 |
| 5674 | 5673 |
| 5675 bool SharedFunctionInfo::IsApiFunction() { | 5674 bool SharedFunctionInfo::IsApiFunction() { |
| 5676 return function_data()->IsFunctionTemplateInfo(); | 5675 return function_data()->IsFunctionTemplateInfo(); |
| 5677 } | 5676 } |
| 5678 | 5677 |
| 5679 | 5678 |
| 5680 FunctionTemplateInfo* SharedFunctionInfo::get_api_func_data() { | 5679 FunctionTemplateInfo* SharedFunctionInfo::get_api_func_data() { |
| 5681 DCHECK(IsApiFunction()); | 5680 DCHECK(IsApiFunction()); |
| (...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5935 return instance_prototype(); | 5934 return instance_prototype(); |
| 5936 } | 5935 } |
| 5937 | 5936 |
| 5938 | 5937 |
| 5939 bool JSFunction::should_have_prototype() { | 5938 bool JSFunction::should_have_prototype() { |
| 5940 return map()->function_with_prototype(); | 5939 return map()->function_with_prototype(); |
| 5941 } | 5940 } |
| 5942 | 5941 |
| 5943 | 5942 |
| 5944 bool JSFunction::is_compiled() { | 5943 bool JSFunction::is_compiled() { |
| 5945 return code() != | 5944 return code() != GetIsolate()->builtins()->builtin(Builtins::kCompileLazy); |
| 5946 GetIsolate()->builtins()->builtin(Builtins::kCompileUnoptimized); | |
| 5947 } | 5945 } |
| 5948 | 5946 |
| 5949 | 5947 |
| 5950 FixedArray* JSFunction::literals() { | 5948 FixedArray* JSFunction::literals() { |
| 5951 DCHECK(!shared()->bound()); | 5949 DCHECK(!shared()->bound()); |
| 5952 return literals_or_bindings(); | 5950 return literals_or_bindings(); |
| 5953 } | 5951 } |
| 5954 | 5952 |
| 5955 | 5953 |
| 5956 void JSFunction::set_literals(FixedArray* literals) { | 5954 void JSFunction::set_literals(FixedArray* literals) { |
| (...skipping 1306 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7263 #undef READ_SHORT_FIELD | 7261 #undef READ_SHORT_FIELD |
| 7264 #undef WRITE_SHORT_FIELD | 7262 #undef WRITE_SHORT_FIELD |
| 7265 #undef READ_BYTE_FIELD | 7263 #undef READ_BYTE_FIELD |
| 7266 #undef WRITE_BYTE_FIELD | 7264 #undef WRITE_BYTE_FIELD |
| 7267 #undef NOBARRIER_READ_BYTE_FIELD | 7265 #undef NOBARRIER_READ_BYTE_FIELD |
| 7268 #undef NOBARRIER_WRITE_BYTE_FIELD | 7266 #undef NOBARRIER_WRITE_BYTE_FIELD |
| 7269 | 7267 |
| 7270 } } // namespace v8::internal | 7268 } } // namespace v8::internal |
| 7271 | 7269 |
| 7272 #endif // V8_OBJECTS_INL_H_ | 7270 #endif // V8_OBJECTS_INL_H_ |
| OLD | NEW |