OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 658 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
669 bool Object::IsCompilationCacheTable() { | 669 bool Object::IsCompilationCacheTable() { |
670 return IsHashTable(); | 670 return IsHashTable(); |
671 } | 671 } |
672 | 672 |
673 | 673 |
674 bool Object::IsCodeCacheHashTable() { | 674 bool Object::IsCodeCacheHashTable() { |
675 return IsHashTable(); | 675 return IsHashTable(); |
676 } | 676 } |
677 | 677 |
678 | 678 |
| 679 bool Object::IsPolymorphicCodeCacheHashTable() { |
| 680 return IsHashTable(); |
| 681 } |
| 682 |
| 683 |
679 bool Object::IsMapCache() { | 684 bool Object::IsMapCache() { |
680 return IsHashTable(); | 685 return IsHashTable(); |
681 } | 686 } |
682 | 687 |
683 | 688 |
684 bool Object::IsPrimitive() { | 689 bool Object::IsPrimitive() { |
685 return IsOddball() || IsNumber() || IsString(); | 690 return IsOddball() || IsNumber() || IsString(); |
686 } | 691 } |
687 | 692 |
688 | 693 |
(...skipping 1195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1884 | 1889 |
1885 CAST_ACCESSOR(FixedArray) | 1890 CAST_ACCESSOR(FixedArray) |
1886 CAST_ACCESSOR(DescriptorArray) | 1891 CAST_ACCESSOR(DescriptorArray) |
1887 CAST_ACCESSOR(DeoptimizationInputData) | 1892 CAST_ACCESSOR(DeoptimizationInputData) |
1888 CAST_ACCESSOR(DeoptimizationOutputData) | 1893 CAST_ACCESSOR(DeoptimizationOutputData) |
1889 CAST_ACCESSOR(SymbolTable) | 1894 CAST_ACCESSOR(SymbolTable) |
1890 CAST_ACCESSOR(JSFunctionResultCache) | 1895 CAST_ACCESSOR(JSFunctionResultCache) |
1891 CAST_ACCESSOR(NormalizedMapCache) | 1896 CAST_ACCESSOR(NormalizedMapCache) |
1892 CAST_ACCESSOR(CompilationCacheTable) | 1897 CAST_ACCESSOR(CompilationCacheTable) |
1893 CAST_ACCESSOR(CodeCacheHashTable) | 1898 CAST_ACCESSOR(CodeCacheHashTable) |
| 1899 CAST_ACCESSOR(PolymorphicCodeCacheHashTable) |
1894 CAST_ACCESSOR(MapCache) | 1900 CAST_ACCESSOR(MapCache) |
1895 CAST_ACCESSOR(String) | 1901 CAST_ACCESSOR(String) |
1896 CAST_ACCESSOR(SeqString) | 1902 CAST_ACCESSOR(SeqString) |
1897 CAST_ACCESSOR(SeqAsciiString) | 1903 CAST_ACCESSOR(SeqAsciiString) |
1898 CAST_ACCESSOR(SeqTwoByteString) | 1904 CAST_ACCESSOR(SeqTwoByteString) |
1899 CAST_ACCESSOR(ConsString) | 1905 CAST_ACCESSOR(ConsString) |
1900 CAST_ACCESSOR(ExternalString) | 1906 CAST_ACCESSOR(ExternalString) |
1901 CAST_ACCESSOR(ExternalAsciiString) | 1907 CAST_ACCESSOR(ExternalAsciiString) |
1902 CAST_ACCESSOR(ExternalTwoByteString) | 1908 CAST_ACCESSOR(ExternalTwoByteString) |
1903 CAST_ACCESSOR(JSObject) | 1909 CAST_ACCESSOR(JSObject) |
(...skipping 1413 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3317 void SharedFunctionInfo::set_native(bool value) { | 3323 void SharedFunctionInfo::set_native(bool value) { |
3318 set_compiler_hints(BooleanBit::set(compiler_hints(), | 3324 set_compiler_hints(BooleanBit::set(compiler_hints(), |
3319 kNative, | 3325 kNative, |
3320 value)); | 3326 value)); |
3321 } | 3327 } |
3322 | 3328 |
3323 | 3329 |
3324 ACCESSORS(CodeCache, default_cache, FixedArray, kDefaultCacheOffset) | 3330 ACCESSORS(CodeCache, default_cache, FixedArray, kDefaultCacheOffset) |
3325 ACCESSORS(CodeCache, normal_type_cache, Object, kNormalTypeCacheOffset) | 3331 ACCESSORS(CodeCache, normal_type_cache, Object, kNormalTypeCacheOffset) |
3326 | 3332 |
| 3333 ACCESSORS(PolymorphicCodeCache, cache, Object, kCacheOffset) |
| 3334 |
3327 bool Script::HasValidSource() { | 3335 bool Script::HasValidSource() { |
3328 Object* src = this->source(); | 3336 Object* src = this->source(); |
3329 if (!src->IsString()) return true; | 3337 if (!src->IsString()) return true; |
3330 String* src_str = String::cast(src); | 3338 String* src_str = String::cast(src); |
3331 if (!StringShape(src_str).IsExternal()) return true; | 3339 if (!StringShape(src_str).IsExternal()) return true; |
3332 if (src_str->IsAsciiRepresentation()) { | 3340 if (src_str->IsAsciiRepresentation()) { |
3333 return ExternalAsciiString::cast(src)->resource() != NULL; | 3341 return ExternalAsciiString::cast(src)->resource() != NULL; |
3334 } else if (src_str->IsTwoByteRepresentation()) { | 3342 } else if (src_str->IsTwoByteRepresentation()) { |
3335 return ExternalTwoByteString::cast(src)->resource() != NULL; | 3343 return ExternalTwoByteString::cast(src)->resource() != NULL; |
3336 } | 3344 } |
(...skipping 977 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4314 #undef WRITE_INT_FIELD | 4322 #undef WRITE_INT_FIELD |
4315 #undef READ_SHORT_FIELD | 4323 #undef READ_SHORT_FIELD |
4316 #undef WRITE_SHORT_FIELD | 4324 #undef WRITE_SHORT_FIELD |
4317 #undef READ_BYTE_FIELD | 4325 #undef READ_BYTE_FIELD |
4318 #undef WRITE_BYTE_FIELD | 4326 #undef WRITE_BYTE_FIELD |
4319 | 4327 |
4320 | 4328 |
4321 } } // namespace v8::internal | 4329 } } // namespace v8::internal |
4322 | 4330 |
4323 #endif // V8_OBJECTS_INL_H_ | 4331 #endif // V8_OBJECTS_INL_H_ |
OLD | NEW |