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_OBJECTS_H_ | 5 #ifndef V8_OBJECTS_H_ |
6 #define V8_OBJECTS_H_ | 6 #define V8_OBJECTS_H_ |
7 | 7 |
8 #include <iosfwd> | 8 #include <iosfwd> |
9 | 9 |
10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 // - AccessorInfo | 133 // - AccessorInfo |
134 // - ExecutableAccessorInfo | 134 // - ExecutableAccessorInfo |
135 // - AccessorPair | 135 // - AccessorPair |
136 // - AccessCheckInfo | 136 // - AccessCheckInfo |
137 // - InterceptorInfo | 137 // - InterceptorInfo |
138 // - CallHandlerInfo | 138 // - CallHandlerInfo |
139 // - TemplateInfo | 139 // - TemplateInfo |
140 // - FunctionTemplateInfo | 140 // - FunctionTemplateInfo |
141 // - ObjectTemplateInfo | 141 // - ObjectTemplateInfo |
142 // - Script | 142 // - Script |
143 // - SignatureInfo | |
144 // - TypeSwitchInfo | 143 // - TypeSwitchInfo |
145 // - DebugInfo | 144 // - DebugInfo |
146 // - BreakPointInfo | 145 // - BreakPointInfo |
147 // - CodeCache | 146 // - CodeCache |
148 // - WeakCell | 147 // - WeakCell |
149 // | 148 // |
150 // Formats of Object*: | 149 // Formats of Object*: |
151 // Smi: [31 bit signed int] 0 | 150 // Smi: [31 bit signed int] 0 |
152 // HeapObject: [32 bit direct pointer] (4 byte aligned) | 01 | 151 // HeapObject: [32 bit direct pointer] (4 byte aligned) | 01 |
153 | 152 |
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
520 // manually. | 519 // manually. |
521 #define STRUCT_LIST(V) \ | 520 #define STRUCT_LIST(V) \ |
522 V(BOX, Box, box) \ | 521 V(BOX, Box, box) \ |
523 V(EXECUTABLE_ACCESSOR_INFO, ExecutableAccessorInfo, executable_accessor_info)\ | 522 V(EXECUTABLE_ACCESSOR_INFO, ExecutableAccessorInfo, executable_accessor_info)\ |
524 V(ACCESSOR_PAIR, AccessorPair, accessor_pair) \ | 523 V(ACCESSOR_PAIR, AccessorPair, accessor_pair) \ |
525 V(ACCESS_CHECK_INFO, AccessCheckInfo, access_check_info) \ | 524 V(ACCESS_CHECK_INFO, AccessCheckInfo, access_check_info) \ |
526 V(INTERCEPTOR_INFO, InterceptorInfo, interceptor_info) \ | 525 V(INTERCEPTOR_INFO, InterceptorInfo, interceptor_info) \ |
527 V(CALL_HANDLER_INFO, CallHandlerInfo, call_handler_info) \ | 526 V(CALL_HANDLER_INFO, CallHandlerInfo, call_handler_info) \ |
528 V(FUNCTION_TEMPLATE_INFO, FunctionTemplateInfo, function_template_info) \ | 527 V(FUNCTION_TEMPLATE_INFO, FunctionTemplateInfo, function_template_info) \ |
529 V(OBJECT_TEMPLATE_INFO, ObjectTemplateInfo, object_template_info) \ | 528 V(OBJECT_TEMPLATE_INFO, ObjectTemplateInfo, object_template_info) \ |
530 V(SIGNATURE_INFO, SignatureInfo, signature_info) \ | |
531 V(TYPE_SWITCH_INFO, TypeSwitchInfo, type_switch_info) \ | 529 V(TYPE_SWITCH_INFO, TypeSwitchInfo, type_switch_info) \ |
532 V(SCRIPT, Script, script) \ | 530 V(SCRIPT, Script, script) \ |
533 V(ALLOCATION_SITE, AllocationSite, allocation_site) \ | 531 V(ALLOCATION_SITE, AllocationSite, allocation_site) \ |
534 V(ALLOCATION_MEMENTO, AllocationMemento, allocation_memento) \ | 532 V(ALLOCATION_MEMENTO, AllocationMemento, allocation_memento) \ |
535 V(CODE_CACHE, CodeCache, code_cache) \ | 533 V(CODE_CACHE, CodeCache, code_cache) \ |
536 V(POLYMORPHIC_CODE_CACHE, PolymorphicCodeCache, polymorphic_code_cache) \ | 534 V(POLYMORPHIC_CODE_CACHE, PolymorphicCodeCache, polymorphic_code_cache) \ |
537 V(TYPE_FEEDBACK_INFO, TypeFeedbackInfo, type_feedback_info) \ | 535 V(TYPE_FEEDBACK_INFO, TypeFeedbackInfo, type_feedback_info) \ |
538 V(ALIASED_ARGUMENTS_ENTRY, AliasedArgumentsEntry, aliased_arguments_entry) \ | 536 V(ALIASED_ARGUMENTS_ENTRY, AliasedArgumentsEntry, aliased_arguments_entry) \ |
539 V(DEBUG_INFO, DebugInfo, debug_info) \ | 537 V(DEBUG_INFO, DebugInfo, debug_info) \ |
540 V(BREAK_POINT_INFO, BreakPointInfo, break_point_info) | 538 V(BREAK_POINT_INFO, BreakPointInfo, break_point_info) |
(...skipping 10136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10677 DECLARE_PRINTER(ObjectTemplateInfo) | 10675 DECLARE_PRINTER(ObjectTemplateInfo) |
10678 DECLARE_VERIFIER(ObjectTemplateInfo) | 10676 DECLARE_VERIFIER(ObjectTemplateInfo) |
10679 | 10677 |
10680 static const int kConstructorOffset = TemplateInfo::kHeaderSize; | 10678 static const int kConstructorOffset = TemplateInfo::kHeaderSize; |
10681 static const int kInternalFieldCountOffset = | 10679 static const int kInternalFieldCountOffset = |
10682 kConstructorOffset + kPointerSize; | 10680 kConstructorOffset + kPointerSize; |
10683 static const int kSize = kInternalFieldCountOffset + kPointerSize; | 10681 static const int kSize = kInternalFieldCountOffset + kPointerSize; |
10684 }; | 10682 }; |
10685 | 10683 |
10686 | 10684 |
10687 class SignatureInfo: public Struct { | |
10688 public: | |
10689 DECL_ACCESSORS(receiver, Object) | |
10690 DECL_ACCESSORS(args, Object) | |
10691 | |
10692 DECLARE_CAST(SignatureInfo) | |
10693 | |
10694 // Dispatched behavior. | |
10695 DECLARE_PRINTER(SignatureInfo) | |
10696 DECLARE_VERIFIER(SignatureInfo) | |
10697 | |
10698 static const int kReceiverOffset = Struct::kHeaderSize; | |
10699 static const int kArgsOffset = kReceiverOffset + kPointerSize; | |
10700 static const int kSize = kArgsOffset + kPointerSize; | |
10701 | |
10702 private: | |
10703 DISALLOW_IMPLICIT_CONSTRUCTORS(SignatureInfo); | |
10704 }; | |
10705 | |
10706 | |
10707 class TypeSwitchInfo: public Struct { | 10685 class TypeSwitchInfo: public Struct { |
10708 public: | 10686 public: |
10709 DECL_ACCESSORS(types, Object) | 10687 DECL_ACCESSORS(types, Object) |
10710 | 10688 |
10711 DECLARE_CAST(TypeSwitchInfo) | 10689 DECLARE_CAST(TypeSwitchInfo) |
10712 | 10690 |
10713 // Dispatched behavior. | 10691 // Dispatched behavior. |
10714 DECLARE_PRINTER(TypeSwitchInfo) | 10692 DECLARE_PRINTER(TypeSwitchInfo) |
10715 DECLARE_VERIFIER(TypeSwitchInfo) | 10693 DECLARE_VERIFIER(TypeSwitchInfo) |
10716 | 10694 |
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10956 } else { | 10934 } else { |
10957 value &= ~(1 << bit_position); | 10935 value &= ~(1 << bit_position); |
10958 } | 10936 } |
10959 return value; | 10937 return value; |
10960 } | 10938 } |
10961 }; | 10939 }; |
10962 | 10940 |
10963 } } // namespace v8::internal | 10941 } } // namespace v8::internal |
10964 | 10942 |
10965 #endif // V8_OBJECTS_H_ | 10943 #endif // V8_OBJECTS_H_ |
OLD | NEW |