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 #ifndef V8_CODE_STUBS_H_ | 5 #ifndef V8_CODE_STUBS_H_ |
6 #define V8_CODE_STUBS_H_ | 6 #define V8_CODE_STUBS_H_ |
7 | 7 |
8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
9 #include "src/assembler.h" | 9 #include "src/assembler.h" |
10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 V(CreateAllocationSite) \ | 46 V(CreateAllocationSite) \ |
47 V(ToBoolean) \ | 47 V(ToBoolean) \ |
48 V(ToNumber) \ | 48 V(ToNumber) \ |
49 V(ArgumentsAccess) \ | 49 V(ArgumentsAccess) \ |
50 V(RegExpConstructResult) \ | 50 V(RegExpConstructResult) \ |
51 V(NumberToString) \ | 51 V(NumberToString) \ |
52 V(DoubleToI) \ | 52 V(DoubleToI) \ |
53 V(CEntry) \ | 53 V(CEntry) \ |
54 V(JSEntry) \ | 54 V(JSEntry) \ |
55 V(KeyedLoadElement) \ | 55 V(KeyedLoadElement) \ |
56 V(KeyedLoadGeneric) \ | |
57 V(ArrayNoArgumentConstructor) \ | 56 V(ArrayNoArgumentConstructor) \ |
58 V(ArraySingleArgumentConstructor) \ | 57 V(ArraySingleArgumentConstructor) \ |
59 V(ArrayNArgumentsConstructor) \ | 58 V(ArrayNArgumentsConstructor) \ |
60 V(InternalArrayNoArgumentConstructor) \ | 59 V(InternalArrayNoArgumentConstructor) \ |
61 V(InternalArraySingleArgumentConstructor) \ | 60 V(InternalArraySingleArgumentConstructor) \ |
62 V(InternalArrayNArgumentsConstructor) \ | 61 V(InternalArrayNArgumentsConstructor) \ |
63 V(KeyedStoreElement) \ | 62 V(KeyedStoreElement) \ |
64 V(DebuggerStatement) \ | 63 V(DebuggerStatement) \ |
65 V(NameDictionaryLookup) \ | 64 V(NameDictionaryLookup) \ |
66 V(ElementsTransitionAndStore) \ | 65 V(ElementsTransitionAndStore) \ |
(...skipping 1772 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1839 void Generate(MacroAssembler* masm); | 1838 void Generate(MacroAssembler* masm); |
1840 | 1839 |
1841 private: | 1840 private: |
1842 Major MajorKey() { return KeyedLoadElement; } | 1841 Major MajorKey() { return KeyedLoadElement; } |
1843 int MinorKey() { return DICTIONARY_ELEMENTS; } | 1842 int MinorKey() { return DICTIONARY_ELEMENTS; } |
1844 | 1843 |
1845 DISALLOW_COPY_AND_ASSIGN(KeyedLoadDictionaryElementPlatformStub); | 1844 DISALLOW_COPY_AND_ASSIGN(KeyedLoadDictionaryElementPlatformStub); |
1846 }; | 1845 }; |
1847 | 1846 |
1848 | 1847 |
1849 class KeyedLoadGenericElementStub : public HydrogenCodeStub { | |
1850 public: | |
1851 explicit KeyedLoadGenericElementStub(Isolate *isolate) | |
1852 : HydrogenCodeStub(isolate) {} | |
1853 | |
1854 virtual Handle<Code> GenerateCode() V8_OVERRIDE; | |
1855 | |
1856 virtual void InitializeInterfaceDescriptor( | |
1857 CodeStubInterfaceDescriptor* descriptor) V8_OVERRIDE; | |
1858 | |
1859 static void InstallDescriptors(Isolate* isolate); | |
1860 | |
1861 virtual Code::Kind GetCodeKind() const { return Code::KEYED_LOAD_IC; } | |
1862 virtual InlineCacheState GetICState() { return GENERIC; } | |
1863 | |
1864 private: | |
1865 Major MajorKey() { return KeyedLoadGeneric; } | |
1866 int NotMissMinorKey() { return 0; } | |
1867 | |
1868 DISALLOW_COPY_AND_ASSIGN(KeyedLoadGenericElementStub); | |
1869 }; | |
1870 | |
1871 | |
1872 class DoubleToIStub : public PlatformCodeStub { | 1848 class DoubleToIStub : public PlatformCodeStub { |
1873 public: | 1849 public: |
1874 DoubleToIStub(Isolate* isolate, | 1850 DoubleToIStub(Isolate* isolate, |
1875 Register source, | 1851 Register source, |
1876 Register destination, | 1852 Register destination, |
1877 int offset, | 1853 int offset, |
1878 bool is_truncating, | 1854 bool is_truncating, |
1879 bool skip_fastpath = false) | 1855 bool skip_fastpath = false) |
1880 : PlatformCodeStub(isolate), bit_field_(0) { | 1856 : PlatformCodeStub(isolate), bit_field_(0) { |
1881 bit_field_ = SourceRegisterBits::encode(source.code()) | | 1857 bit_field_ = SourceRegisterBits::encode(source.code()) | |
(...skipping 601 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2483 | 2459 |
2484 | 2460 |
2485 class CallDescriptors { | 2461 class CallDescriptors { |
2486 public: | 2462 public: |
2487 static void InitializeForIsolate(Isolate* isolate); | 2463 static void InitializeForIsolate(Isolate* isolate); |
2488 }; | 2464 }; |
2489 | 2465 |
2490 } } // namespace v8::internal | 2466 } } // namespace v8::internal |
2491 | 2467 |
2492 #endif // V8_CODE_STUBS_H_ | 2468 #endif // V8_CODE_STUBS_H_ |
OLD | NEW |