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 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #include "src/bootstrapper.h" | 7 #include "src/bootstrapper.h" |
8 #include "src/code-stubs.h" | 8 #include "src/code-stubs.h" |
9 #include "src/cpu-profiler.h" | 9 #include "src/cpu-profiler.h" |
10 #include "src/factory.h" | 10 #include "src/factory.h" |
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
226 } | 226 } |
227 | 227 |
228 | 228 |
229 const char* CodeStub::MajorName(CodeStub::Major major_key, | 229 const char* CodeStub::MajorName(CodeStub::Major major_key, |
230 bool allow_unknown_keys) { | 230 bool allow_unknown_keys) { |
231 switch (major_key) { | 231 switch (major_key) { |
232 #define DEF_CASE(name) case name: return #name "Stub"; | 232 #define DEF_CASE(name) case name: return #name "Stub"; |
233 CODE_STUB_LIST(DEF_CASE) | 233 CODE_STUB_LIST(DEF_CASE) |
234 #undef DEF_CASE | 234 #undef DEF_CASE |
235 case UninitializedMajorKey: return "<UninitializedMajorKey>Stub"; | 235 case UninitializedMajorKey: return "<UninitializedMajorKey>Stub"; |
| 236 case NoCache: |
| 237 return "<NoCache>Stub"; |
236 default: | 238 default: |
237 if (!allow_unknown_keys) { | 239 if (!allow_unknown_keys) { |
238 UNREACHABLE(); | 240 UNREACHABLE(); |
239 } | 241 } |
240 return NULL; | 242 return NULL; |
241 } | 243 } |
242 } | 244 } |
243 | 245 |
244 | 246 |
245 void CodeStub::PrintBaseName(OStream& os) const { // NOLINT | 247 void CodeStub::PrintBaseName(OStream& os) const { // NOLINT |
(...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
661 StoreIC::ReceiverRegister(), | 663 StoreIC::ReceiverRegister(), |
662 StoreIC::NameRegister(), | 664 StoreIC::NameRegister(), |
663 StoreIC::ValueRegister() }; | 665 StoreIC::ValueRegister() }; |
664 descriptor->Initialize(ARRAY_SIZE(registers), registers, | 666 descriptor->Initialize(ARRAY_SIZE(registers), registers, |
665 FUNCTION_ADDR(StoreIC_MissFromStubFailure)); | 667 FUNCTION_ADDR(StoreIC_MissFromStubFailure)); |
666 } | 668 } |
667 | 669 |
668 | 670 |
669 void KeyedLoadDictionaryElementPlatformStub::Generate( | 671 void KeyedLoadDictionaryElementPlatformStub::Generate( |
670 MacroAssembler* masm) { | 672 MacroAssembler* masm) { |
671 KeyedLoadStubCompiler::GenerateLoadDictionaryElement(masm); | 673 IndexedHandlerCompiler::GenerateLoadDictionaryElement(masm); |
672 } | 674 } |
673 | 675 |
674 | 676 |
675 void CreateAllocationSiteStub::GenerateAheadOfTime(Isolate* isolate) { | 677 void CreateAllocationSiteStub::GenerateAheadOfTime(Isolate* isolate) { |
676 CreateAllocationSiteStub stub(isolate); | 678 CreateAllocationSiteStub stub(isolate); |
677 stub.GetCode(); | 679 stub.GetCode(); |
678 } | 680 } |
679 | 681 |
680 | 682 |
681 void KeyedStoreElementStub::Generate(MacroAssembler* masm) { | 683 void KeyedStoreElementStub::Generate(MacroAssembler* masm) { |
682 switch (elements_kind_) { | 684 switch (elements_kind_) { |
683 case FAST_ELEMENTS: | 685 case FAST_ELEMENTS: |
684 case FAST_HOLEY_ELEMENTS: | 686 case FAST_HOLEY_ELEMENTS: |
685 case FAST_SMI_ELEMENTS: | 687 case FAST_SMI_ELEMENTS: |
686 case FAST_HOLEY_SMI_ELEMENTS: | 688 case FAST_HOLEY_SMI_ELEMENTS: |
687 case FAST_DOUBLE_ELEMENTS: | 689 case FAST_DOUBLE_ELEMENTS: |
688 case FAST_HOLEY_DOUBLE_ELEMENTS: | 690 case FAST_HOLEY_DOUBLE_ELEMENTS: |
689 #define TYPED_ARRAY_CASE(Type, type, TYPE, ctype, size) \ | 691 #define TYPED_ARRAY_CASE(Type, type, TYPE, ctype, size) \ |
690 case EXTERNAL_##TYPE##_ELEMENTS: \ | 692 case EXTERNAL_##TYPE##_ELEMENTS: \ |
691 case TYPE##_ELEMENTS: | 693 case TYPE##_ELEMENTS: |
692 | 694 |
693 TYPED_ARRAYS(TYPED_ARRAY_CASE) | 695 TYPED_ARRAYS(TYPED_ARRAY_CASE) |
694 #undef TYPED_ARRAY_CASE | 696 #undef TYPED_ARRAY_CASE |
695 UNREACHABLE(); | 697 UNREACHABLE(); |
696 break; | 698 break; |
697 case DICTIONARY_ELEMENTS: | 699 case DICTIONARY_ELEMENTS: |
698 KeyedStoreStubCompiler::GenerateStoreDictionaryElement(masm); | 700 IndexedHandlerCompiler::GenerateStoreDictionaryElement(masm); |
699 break; | 701 break; |
700 case SLOPPY_ARGUMENTS_ELEMENTS: | 702 case SLOPPY_ARGUMENTS_ELEMENTS: |
701 UNREACHABLE(); | 703 UNREACHABLE(); |
702 break; | 704 break; |
703 } | 705 } |
704 } | 706 } |
705 | 707 |
706 | 708 |
707 void ArgumentsAccessStub::PrintName(OStream& os) const { // NOLINT | 709 void ArgumentsAccessStub::PrintName(OStream& os) const { // NOLINT |
708 os << "ArgumentsAccessStub_"; | 710 os << "ArgumentsAccessStub_"; |
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
973 InstallDescriptor(isolate, &stub3); | 975 InstallDescriptor(isolate, &stub3); |
974 } | 976 } |
975 | 977 |
976 InternalArrayConstructorStub::InternalArrayConstructorStub( | 978 InternalArrayConstructorStub::InternalArrayConstructorStub( |
977 Isolate* isolate) : PlatformCodeStub(isolate) { | 979 Isolate* isolate) : PlatformCodeStub(isolate) { |
978 InternalArrayConstructorStubBase::GenerateStubsAheadOfTime(isolate); | 980 InternalArrayConstructorStubBase::GenerateStubsAheadOfTime(isolate); |
979 } | 981 } |
980 | 982 |
981 | 983 |
982 } } // namespace v8::internal | 984 } } // namespace v8::internal |
OLD | NEW |