| 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 559 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 570 StrictMode strict_mode() const { | 570 StrictMode strict_mode() const { |
| 571 return StrictModeBits::decode(sub_minor_key()); | 571 return StrictModeBits::decode(sub_minor_key()); |
| 572 } | 572 } |
| 573 | 573 |
| 574 FunctionKind kind() const { | 574 FunctionKind kind() const { |
| 575 return FunctionKindBits::decode(sub_minor_key()); | 575 return FunctionKindBits::decode(sub_minor_key()); |
| 576 } | 576 } |
| 577 bool is_arrow() const { return IsArrowFunction(kind()); } | 577 bool is_arrow() const { return IsArrowFunction(kind()); } |
| 578 bool is_generator() const { return IsGeneratorFunction(kind()); } | 578 bool is_generator() const { return IsGeneratorFunction(kind()); } |
| 579 bool is_concise_method() const { return IsConciseMethod(kind()); } | 579 bool is_concise_method() const { return IsConciseMethod(kind()); } |
| 580 bool is_default_constructor() const { return IsDefaultConstructor(kind()); } |
| 581 bool is_default_constructor_call_super() const { |
| 582 return IsDefaultConstructorCallSuper(kind()); |
| 583 } |
| 580 | 584 |
| 581 private: | 585 private: |
| 582 class StrictModeBits : public BitField<StrictMode, 0, 1> {}; | 586 class StrictModeBits : public BitField<StrictMode, 0, 1> {}; |
| 583 class FunctionKindBits : public BitField<FunctionKind, 1, 3> {}; | 587 class FunctionKindBits : public BitField<FunctionKind, 1, 5> {}; |
| 584 | 588 |
| 585 DEFINE_CALL_INTERFACE_DESCRIPTOR(FastNewClosure); | 589 DEFINE_CALL_INTERFACE_DESCRIPTOR(FastNewClosure); |
| 586 DEFINE_HYDROGEN_CODE_STUB(FastNewClosure, HydrogenCodeStub); | 590 DEFINE_HYDROGEN_CODE_STUB(FastNewClosure, HydrogenCodeStub); |
| 587 }; | 591 }; |
| 588 | 592 |
| 589 | 593 |
| 590 class FastNewContextStub FINAL : public HydrogenCodeStub { | 594 class FastNewContextStub FINAL : public HydrogenCodeStub { |
| 591 public: | 595 public: |
| 592 static const int kMaximumSlots = 64; | 596 static const int kMaximumSlots = 64; |
| 593 | 597 |
| (...skipping 1954 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2548 | 2552 |
| 2549 #undef DEFINE_CALL_INTERFACE_DESCRIPTOR | 2553 #undef DEFINE_CALL_INTERFACE_DESCRIPTOR |
| 2550 #undef DEFINE_PLATFORM_CODE_STUB | 2554 #undef DEFINE_PLATFORM_CODE_STUB |
| 2551 #undef DEFINE_HANDLER_CODE_STUB | 2555 #undef DEFINE_HANDLER_CODE_STUB |
| 2552 #undef DEFINE_HYDROGEN_CODE_STUB | 2556 #undef DEFINE_HYDROGEN_CODE_STUB |
| 2553 #undef DEFINE_CODE_STUB | 2557 #undef DEFINE_CODE_STUB |
| 2554 #undef DEFINE_CODE_STUB_BASE | 2558 #undef DEFINE_CODE_STUB_BASE |
| 2555 } } // namespace v8::internal | 2559 } } // namespace v8::internal |
| 2556 | 2560 |
| 2557 #endif // V8_CODE_STUBS_H_ | 2561 #endif // V8_CODE_STUBS_H_ |
| OLD | NEW |