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 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 V(JSEntry) \ | 43 V(JSEntry) \ |
44 V(LoadIndexedString) \ | 44 V(LoadIndexedString) \ |
45 V(MathPow) \ | 45 V(MathPow) \ |
46 V(ProfileEntryHook) \ | 46 V(ProfileEntryHook) \ |
47 V(RecordWrite) \ | 47 V(RecordWrite) \ |
48 V(RegExpExec) \ | 48 V(RegExpExec) \ |
49 V(StoreBufferOverflow) \ | 49 V(StoreBufferOverflow) \ |
50 V(StoreElement) \ | 50 V(StoreElement) \ |
51 V(SubString) \ | 51 V(SubString) \ |
52 V(LoadGlobalIC) \ | 52 V(LoadGlobalIC) \ |
53 V(FastNewObject) \ | |
54 V(FastNewRestParameter) \ | 53 V(FastNewRestParameter) \ |
55 V(FastNewSloppyArguments) \ | 54 V(FastNewSloppyArguments) \ |
56 V(FastNewStrictArguments) \ | 55 V(FastNewStrictArguments) \ |
57 V(NameDictionaryLookup) \ | 56 V(NameDictionaryLookup) \ |
58 /* This can be removed once there are no */ \ | 57 /* This can be removed once there are no */ \ |
59 /* more deopting Hydrogen stubs. */ \ | 58 /* more deopting Hydrogen stubs. */ \ |
60 V(StubFailureTrampoline) \ | 59 V(StubFailureTrampoline) \ |
61 /* These are only called from FCG */ \ | 60 /* These are only called from FCG */ \ |
62 /* They can be removed when only the TF */ \ | 61 /* They can be removed when only the TF */ \ |
63 /* version of the corresponding stub is */ \ | 62 /* version of the corresponding stub is */ \ |
(...skipping 732 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
796 // new space. | 795 // new space. |
797 STATIC_ASSERT(((kMaximumSlots + Context::MIN_CONTEXT_SLOTS) * kPointerSize + | 796 STATIC_ASSERT(((kMaximumSlots + Context::MIN_CONTEXT_SLOTS) * kPointerSize + |
798 FixedArray::kHeaderSize) < kMaxRegularHeapObjectSize); | 797 FixedArray::kHeaderSize) < kMaxRegularHeapObjectSize); |
799 | 798 |
800 class ScopeTypeBits : public BitField<bool, 0, 8> {}; | 799 class ScopeTypeBits : public BitField<bool, 0, 8> {}; |
801 | 800 |
802 DEFINE_CALL_INTERFACE_DESCRIPTOR(FastNewFunctionContext); | 801 DEFINE_CALL_INTERFACE_DESCRIPTOR(FastNewFunctionContext); |
803 DEFINE_TURBOFAN_CODE_STUB(FastNewFunctionContext, TurboFanCodeStub); | 802 DEFINE_TURBOFAN_CODE_STUB(FastNewFunctionContext, TurboFanCodeStub); |
804 }; | 803 }; |
805 | 804 |
806 class FastNewObjectStub final : public PlatformCodeStub { | |
807 public: | |
808 explicit FastNewObjectStub(Isolate* isolate) : PlatformCodeStub(isolate) {} | |
809 | |
810 DEFINE_CALL_INTERFACE_DESCRIPTOR(FastNewObject); | |
811 DEFINE_PLATFORM_CODE_STUB(FastNewObject, PlatformCodeStub); | |
812 }; | |
813 | |
814 | |
815 // TODO(turbofan): This stub should be possible to write in TurboFan | 805 // TODO(turbofan): This stub should be possible to write in TurboFan |
816 // using the CodeStubAssembler very soon in a way that is as efficient | 806 // using the CodeStubAssembler very soon in a way that is as efficient |
817 // and easy as the current handwritten version, which is partly a copy | 807 // and easy as the current handwritten version, which is partly a copy |
818 // of the strict arguments object materialization code. | 808 // of the strict arguments object materialization code. |
819 class FastNewRestParameterStub final : public PlatformCodeStub { | 809 class FastNewRestParameterStub final : public PlatformCodeStub { |
820 public: | 810 public: |
821 explicit FastNewRestParameterStub(Isolate* isolate, | 811 explicit FastNewRestParameterStub(Isolate* isolate, |
822 bool skip_stub_frame = false) | 812 bool skip_stub_frame = false) |
823 : PlatformCodeStub(isolate) { | 813 : PlatformCodeStub(isolate) { |
824 minor_key_ = SkipStubFrameBits::encode(skip_stub_frame); | 814 minor_key_ = SkipStubFrameBits::encode(skip_stub_frame); |
(...skipping 1630 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2455 #undef DEFINE_PLATFORM_CODE_STUB | 2445 #undef DEFINE_PLATFORM_CODE_STUB |
2456 #undef DEFINE_HANDLER_CODE_STUB | 2446 #undef DEFINE_HANDLER_CODE_STUB |
2457 #undef DEFINE_HYDROGEN_CODE_STUB | 2447 #undef DEFINE_HYDROGEN_CODE_STUB |
2458 #undef DEFINE_CODE_STUB | 2448 #undef DEFINE_CODE_STUB |
2459 #undef DEFINE_CODE_STUB_BASE | 2449 #undef DEFINE_CODE_STUB_BASE |
2460 | 2450 |
2461 } // namespace internal | 2451 } // namespace internal |
2462 } // namespace v8 | 2452 } // namespace v8 |
2463 | 2453 |
2464 #endif // V8_CODE_STUBS_H_ | 2454 #endif // V8_CODE_STUBS_H_ |
OLD | NEW |