OLD | NEW |
---|---|
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 4833 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
4844 // [relocation_info]: Code relocation information | 4844 // [relocation_info]: Code relocation information |
4845 DECL_ACCESSORS(relocation_info, ByteArray) | 4845 DECL_ACCESSORS(relocation_info, ByteArray) |
4846 void InvalidateRelocation(); | 4846 void InvalidateRelocation(); |
4847 | 4847 |
4848 // [handler_table]: Fixed array containing offsets of exception handlers. | 4848 // [handler_table]: Fixed array containing offsets of exception handlers. |
4849 DECL_ACCESSORS(handler_table, FixedArray) | 4849 DECL_ACCESSORS(handler_table, FixedArray) |
4850 | 4850 |
4851 // [deoptimization_data]: Array containing data for deopt. | 4851 // [deoptimization_data]: Array containing data for deopt. |
4852 DECL_ACCESSORS(deoptimization_data, FixedArray) | 4852 DECL_ACCESSORS(deoptimization_data, FixedArray) |
4853 | 4853 |
4854 // [type_feedback_info]: Struct containing type feedback information for | 4854 // [type_feedback_info]: This field stores various things, depending on the |
4855 // unoptimized code. Optimized code can temporarily store the head of | 4855 // kind of the code object. |
4856 // the list of code to be deoptimized during mark-compact GC. | 4856 // FUNCTION => type feedback information. |
4857 // STUBs can use this slot to store arbitrary information as a Smi. | 4857 // STUB => various things, e.g. a SMI |
4858 // Will contain either a TypeFeedbackInfo object, or JSFunction object, | 4858 // OPTIMIZED_FUNCTION => the next_code_link for optimized code list. |
4859 // or undefined, or a Smi. | |
4860 DECL_ACCESSORS(type_feedback_info, Object) | 4859 DECL_ACCESSORS(type_feedback_info, Object) |
4861 inline void InitializeTypeFeedbackInfoNoWriteBarrier(Object* value); | 4860 inline void InitializeTypeFeedbackInfoNoWriteBarrier(Object* value); |
4862 inline int stub_info(); | 4861 inline int stub_info(); |
4863 inline void set_stub_info(int info); | 4862 inline void set_stub_info(int info); |
4864 | 4863 |
4865 // Used during GC to code a list of code objects to deoptimize. | 4864 // [next_code_link]: Link for lists of optimized or deoptimized code. |
4866 inline Object* code_to_deoptimize_link(); | 4865 // Note that storage for this field is overlapped with typefeedback_info. |
4867 inline void set_code_to_deoptimize_link(Object* value); | 4866 DECL_ACCESSORS(next_code_link, Object) |
4868 inline Object** code_to_deoptimize_link_slot(); | |
4869 | 4867 |
4870 // [gc_metadata]: Field used to hold GC related metadata. The contents of this | 4868 // [gc_metadata]: Field used to hold GC related metadata. The contents of this |
4871 // field does not have to be traced during garbage collection since | 4869 // field does not have to be traced during garbage collection since |
4872 // it is only used by the garbage collector itself. | 4870 // it is only used by the garbage collector itself. |
4873 DECL_ACCESSORS(gc_metadata, Object) | 4871 DECL_ACCESSORS(gc_metadata, Object) |
4874 | 4872 |
4875 // [ic_age]: Inline caching age: the value of the Heap::global_ic_age | 4873 // [ic_age]: Inline caching age: the value of the Heap::global_ic_age |
4876 // at the moment when this object was created. | 4874 // at the moment when this object was created. |
4877 inline void set_ic_age(int count); | 4875 inline void set_ic_age(int count); |
4878 inline int ic_age(); | 4876 inline int ic_age(); |
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
5177 static const int kMaxLoopNestingMarker = 6; | 5175 static const int kMaxLoopNestingMarker = 6; |
5178 | 5176 |
5179 // Layout description. | 5177 // Layout description. |
5180 static const int kInstructionSizeOffset = HeapObject::kHeaderSize; | 5178 static const int kInstructionSizeOffset = HeapObject::kHeaderSize; |
5181 static const int kRelocationInfoOffset = kInstructionSizeOffset + kIntSize; | 5179 static const int kRelocationInfoOffset = kInstructionSizeOffset + kIntSize; |
5182 static const int kHandlerTableOffset = kRelocationInfoOffset + kPointerSize; | 5180 static const int kHandlerTableOffset = kRelocationInfoOffset + kPointerSize; |
5183 static const int kDeoptimizationDataOffset = | 5181 static const int kDeoptimizationDataOffset = |
5184 kHandlerTableOffset + kPointerSize; | 5182 kHandlerTableOffset + kPointerSize; |
5185 static const int kTypeFeedbackInfoOffset = | 5183 static const int kTypeFeedbackInfoOffset = |
5186 kDeoptimizationDataOffset + kPointerSize; | 5184 kDeoptimizationDataOffset + kPointerSize; |
5185 static const int kNextCodeLinkOffset = kTypeFeedbackInfoOffset; // Shared. | |
5187 static const int kGCMetadataOffset = kTypeFeedbackInfoOffset + kPointerSize; | 5186 static const int kGCMetadataOffset = kTypeFeedbackInfoOffset + kPointerSize; |
5188 static const int kICAgeOffset = | 5187 static const int kICAgeOffset = |
5189 kGCMetadataOffset + kPointerSize; | 5188 kGCMetadataOffset + kPointerSize; |
5190 static const int kFlagsOffset = kICAgeOffset + kIntSize; | 5189 static const int kFlagsOffset = kICAgeOffset + kIntSize; |
5191 static const int kKindSpecificFlags1Offset = kFlagsOffset + kIntSize; | 5190 static const int kKindSpecificFlags1Offset = kFlagsOffset + kIntSize; |
5192 static const int kKindSpecificFlags2Offset = | 5191 static const int kKindSpecificFlags2Offset = |
5193 kKindSpecificFlags1Offset + kIntSize; | 5192 kKindSpecificFlags1Offset + kIntSize; |
5194 // Note: We might be able to squeeze this into the flags above. | 5193 // Note: We might be able to squeeze this into the flags above. |
5195 static const int kPrologueOffset = kKindSpecificFlags2Offset + kIntSize; | 5194 static const int kPrologueOffset = kKindSpecificFlags2Offset + kIntSize; |
5196 | 5195 |
(...skipping 1923 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
7120 // not have one. Note that this method does not copy the initial map | 7119 // not have one. Note that this method does not copy the initial map |
7121 // if it has one already, but simply replaces it with the new value. | 7120 // if it has one already, but simply replaces it with the new value. |
7122 // Instances created afterwards will have a map whose [[class]] is | 7121 // Instances created afterwards will have a map whose [[class]] is |
7123 // set to 'value', but there is no guarantees on instances created | 7122 // set to 'value', but there is no guarantees on instances created |
7124 // before. | 7123 // before. |
7125 void SetInstanceClassName(String* name); | 7124 void SetInstanceClassName(String* name); |
7126 | 7125 |
7127 // Returns if this function has been compiled to native code yet. | 7126 // Returns if this function has been compiled to native code yet. |
7128 inline bool is_compiled(); | 7127 inline bool is_compiled(); |
7129 | 7128 |
7130 // [next_function_link]: Field for linking functions. This list is treated as | 7129 // [next_function_link]: Links functions into various lists, e.g. the list |
7131 // a weak list by the GC. | 7130 // of optimized functions hanging off the native_context. The CodeFlusher |
7131 // uses this link to chain together flushing candidates. Treatly weakly | |
Michael Starzinger
2013/09/03 21:52:31
nit: s/Treatly/Treated/
titzer
2013/09/04 11:19:04
This weakly treatly brought to you courtesy of a d
| |
7132 // by the garbage collector. | |
7132 DECL_ACCESSORS(next_function_link, Object) | 7133 DECL_ACCESSORS(next_function_link, Object) |
7133 | 7134 |
7134 // Prints the name of the function using PrintF. | 7135 // Prints the name of the function using PrintF. |
7135 inline void PrintName() { | 7136 inline void PrintName() { |
7136 PrintName(stdout); | 7137 PrintName(stdout); |
7137 } | 7138 } |
7138 void PrintName(FILE* out); | 7139 void PrintName(FILE* out); |
7139 | 7140 |
7140 // Casting. | 7141 // Casting. |
7141 static inline JSFunction* cast(Object* obj); | 7142 static inline JSFunction* cast(Object* obj); |
(...skipping 3134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
10276 } else { | 10277 } else { |
10277 value &= ~(1 << bit_position); | 10278 value &= ~(1 << bit_position); |
10278 } | 10279 } |
10279 return value; | 10280 return value; |
10280 } | 10281 } |
10281 }; | 10282 }; |
10282 | 10283 |
10283 } } // namespace v8::internal | 10284 } } // namespace v8::internal |
10284 | 10285 |
10285 #endif // V8_OBJECTS_H_ | 10286 #endif // V8_OBJECTS_H_ |
OLD | NEW |