| 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_HEAP_H_ | 5 #ifndef V8_HEAP_H_ |
| 6 #define V8_HEAP_H_ | 6 #define V8_HEAP_H_ |
| 7 | 7 |
| 8 #include <cmath> | 8 #include <cmath> |
| 9 | 9 |
| 10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 72 V(Oddball, termination_exception, TerminationException) \ | 72 V(Oddball, termination_exception, TerminationException) \ |
| 73 V(Smi, hash_seed, HashSeed) \ | 73 V(Smi, hash_seed, HashSeed) \ |
| 74 V(Map, symbol_map, SymbolMap) \ | 74 V(Map, symbol_map, SymbolMap) \ |
| 75 V(Map, string_map, StringMap) \ | 75 V(Map, string_map, StringMap) \ |
| 76 V(Map, ascii_string_map, AsciiStringMap) \ | 76 V(Map, ascii_string_map, AsciiStringMap) \ |
| 77 V(Map, cons_string_map, ConsStringMap) \ | 77 V(Map, cons_string_map, ConsStringMap) \ |
| 78 V(Map, cons_ascii_string_map, ConsAsciiStringMap) \ | 78 V(Map, cons_ascii_string_map, ConsAsciiStringMap) \ |
| 79 V(Map, sliced_string_map, SlicedStringMap) \ | 79 V(Map, sliced_string_map, SlicedStringMap) \ |
| 80 V(Map, sliced_ascii_string_map, SlicedAsciiStringMap) \ | 80 V(Map, sliced_ascii_string_map, SlicedAsciiStringMap) \ |
| 81 V(Map, external_string_map, ExternalStringMap) \ | 81 V(Map, external_string_map, ExternalStringMap) \ |
| 82 V(Map, \ | 82 V(Map, external_string_with_one_byte_data_map, \ |
| 83 external_string_with_one_byte_data_map, \ | |
| 84 ExternalStringWithOneByteDataMap) \ | 83 ExternalStringWithOneByteDataMap) \ |
| 85 V(Map, external_ascii_string_map, ExternalAsciiStringMap) \ | 84 V(Map, external_ascii_string_map, ExternalAsciiStringMap) \ |
| 86 V(Map, short_external_string_map, ShortExternalStringMap) \ | 85 V(Map, short_external_string_map, ShortExternalStringMap) \ |
| 87 V(Map, \ | 86 V(Map, short_external_string_with_one_byte_data_map, \ |
| 88 short_external_string_with_one_byte_data_map, \ | |
| 89 ShortExternalStringWithOneByteDataMap) \ | 87 ShortExternalStringWithOneByteDataMap) \ |
| 90 V(Map, internalized_string_map, InternalizedStringMap) \ | 88 V(Map, internalized_string_map, InternalizedStringMap) \ |
| 91 V(Map, ascii_internalized_string_map, AsciiInternalizedStringMap) \ | 89 V(Map, ascii_internalized_string_map, AsciiInternalizedStringMap) \ |
| 92 V(Map, \ | 90 V(Map, external_internalized_string_map, ExternalInternalizedStringMap) \ |
| 93 external_internalized_string_map, \ | 91 V(Map, external_internalized_string_with_one_byte_data_map, \ |
| 94 ExternalInternalizedStringMap) \ | |
| 95 V(Map, \ | |
| 96 external_internalized_string_with_one_byte_data_map, \ | |
| 97 ExternalInternalizedStringWithOneByteDataMap) \ | 92 ExternalInternalizedStringWithOneByteDataMap) \ |
| 98 V(Map, \ | 93 V(Map, external_ascii_internalized_string_map, \ |
| 99 external_ascii_internalized_string_map, \ | |
| 100 ExternalAsciiInternalizedStringMap) \ | 94 ExternalAsciiInternalizedStringMap) \ |
| 101 V(Map, \ | 95 V(Map, short_external_internalized_string_map, \ |
| 102 short_external_internalized_string_map, \ | |
| 103 ShortExternalInternalizedStringMap) \ | 96 ShortExternalInternalizedStringMap) \ |
| 104 V(Map, \ | 97 V(Map, short_external_internalized_string_with_one_byte_data_map, \ |
| 105 short_external_internalized_string_with_one_byte_data_map, \ | |
| 106 ShortExternalInternalizedStringWithOneByteDataMap) \ | 98 ShortExternalInternalizedStringWithOneByteDataMap) \ |
| 107 V(Map, \ | 99 V(Map, short_external_ascii_internalized_string_map, \ |
| 108 short_external_ascii_internalized_string_map, \ | |
| 109 ShortExternalAsciiInternalizedStringMap) \ | 100 ShortExternalAsciiInternalizedStringMap) \ |
| 110 V(Map, short_external_ascii_string_map, ShortExternalAsciiStringMap) \ | 101 V(Map, short_external_ascii_string_map, ShortExternalAsciiStringMap) \ |
| 111 V(Map, undetectable_string_map, UndetectableStringMap) \ | 102 V(Map, undetectable_string_map, UndetectableStringMap) \ |
| 112 V(Map, undetectable_ascii_string_map, UndetectableAsciiStringMap) \ | 103 V(Map, undetectable_ascii_string_map, UndetectableAsciiStringMap) \ |
| 113 V(Map, external_int8_array_map, ExternalInt8ArrayMap) \ | 104 V(Map, external_int8_array_map, ExternalInt8ArrayMap) \ |
| 114 V(Map, external_uint8_array_map, ExternalUint8ArrayMap) \ | 105 V(Map, external_uint8_array_map, ExternalUint8ArrayMap) \ |
| 115 V(Map, external_int16_array_map, ExternalInt16ArrayMap) \ | 106 V(Map, external_int16_array_map, ExternalInt16ArrayMap) \ |
| 116 V(Map, external_uint16_array_map, ExternalUint16ArrayMap) \ | 107 V(Map, external_uint16_array_map, ExternalUint16ArrayMap) \ |
| 117 V(Map, external_int32_array_map, ExternalInt32ArrayMap) \ | 108 V(Map, external_int32_array_map, ExternalInt32ArrayMap) \ |
| 118 V(Map, external_uint32_array_map, ExternalUint32ArrayMap) \ | 109 V(Map, external_uint32_array_map, ExternalUint32ArrayMap) \ |
| 119 V(Map, external_float32_array_map, ExternalFloat32ArrayMap) \ | 110 V(Map, external_float32_array_map, ExternalFloat32ArrayMap) \ |
| 120 V(Map, external_float64_array_map, ExternalFloat64ArrayMap) \ | 111 V(Map, external_float64_array_map, ExternalFloat64ArrayMap) \ |
| 121 V(Map, external_uint8_clamped_array_map, ExternalUint8ClampedArrayMap) \ | 112 V(Map, external_uint8_clamped_array_map, ExternalUint8ClampedArrayMap) \ |
| 122 V(ExternalArray, empty_external_int8_array, \ | 113 V(ExternalArray, empty_external_int8_array, EmptyExternalInt8Array) \ |
| 123 EmptyExternalInt8Array) \ | 114 V(ExternalArray, empty_external_uint8_array, EmptyExternalUint8Array) \ |
| 124 V(ExternalArray, empty_external_uint8_array, \ | |
| 125 EmptyExternalUint8Array) \ | |
| 126 V(ExternalArray, empty_external_int16_array, EmptyExternalInt16Array) \ | 115 V(ExternalArray, empty_external_int16_array, EmptyExternalInt16Array) \ |
| 127 V(ExternalArray, empty_external_uint16_array, \ | 116 V(ExternalArray, empty_external_uint16_array, EmptyExternalUint16Array) \ |
| 128 EmptyExternalUint16Array) \ | |
| 129 V(ExternalArray, empty_external_int32_array, EmptyExternalInt32Array) \ | 117 V(ExternalArray, empty_external_int32_array, EmptyExternalInt32Array) \ |
| 130 V(ExternalArray, empty_external_uint32_array, \ | 118 V(ExternalArray, empty_external_uint32_array, EmptyExternalUint32Array) \ |
| 131 EmptyExternalUint32Array) \ | |
| 132 V(ExternalArray, empty_external_float32_array, EmptyExternalFloat32Array) \ | 119 V(ExternalArray, empty_external_float32_array, EmptyExternalFloat32Array) \ |
| 133 V(ExternalArray, empty_external_float64_array, EmptyExternalFloat64Array) \ | 120 V(ExternalArray, empty_external_float64_array, EmptyExternalFloat64Array) \ |
| 134 V(ExternalArray, empty_external_uint8_clamped_array, \ | 121 V(ExternalArray, empty_external_uint8_clamped_array, \ |
| 135 EmptyExternalUint8ClampedArray) \ | 122 EmptyExternalUint8ClampedArray) \ |
| 136 V(Map, fixed_uint8_array_map, FixedUint8ArrayMap) \ | 123 V(Map, fixed_uint8_array_map, FixedUint8ArrayMap) \ |
| 137 V(Map, fixed_int8_array_map, FixedInt8ArrayMap) \ | 124 V(Map, fixed_int8_array_map, FixedInt8ArrayMap) \ |
| 138 V(Map, fixed_uint16_array_map, FixedUint16ArrayMap) \ | 125 V(Map, fixed_uint16_array_map, FixedUint16ArrayMap) \ |
| 139 V(Map, fixed_int16_array_map, FixedInt16ArrayMap) \ | 126 V(Map, fixed_int16_array_map, FixedInt16ArrayMap) \ |
| 140 V(Map, fixed_uint32_array_map, FixedUint32ArrayMap) \ | 127 V(Map, fixed_uint32_array_map, FixedUint32ArrayMap) \ |
| 141 V(Map, fixed_int32_array_map, FixedInt32ArrayMap) \ | 128 V(Map, fixed_int32_array_map, FixedInt32ArrayMap) \ |
| 142 V(Map, fixed_float32_array_map, FixedFloat32ArrayMap) \ | 129 V(Map, fixed_float32_array_map, FixedFloat32ArrayMap) \ |
| 143 V(Map, fixed_float64_array_map, FixedFloat64ArrayMap) \ | 130 V(Map, fixed_float64_array_map, FixedFloat64ArrayMap) \ |
| 144 V(Map, fixed_uint8_clamped_array_map, FixedUint8ClampedArrayMap) \ | 131 V(Map, fixed_uint8_clamped_array_map, FixedUint8ClampedArrayMap) \ |
| 145 V(FixedTypedArrayBase, empty_fixed_uint8_array, EmptyFixedUint8Array) \ | 132 V(FixedTypedArrayBase, empty_fixed_uint8_array, EmptyFixedUint8Array) \ |
| 146 V(FixedTypedArrayBase, empty_fixed_int8_array, EmptyFixedInt8Array) \ | 133 V(FixedTypedArrayBase, empty_fixed_int8_array, EmptyFixedInt8Array) \ |
| 147 V(FixedTypedArrayBase, empty_fixed_uint16_array, EmptyFixedUint16Array) \ | 134 V(FixedTypedArrayBase, empty_fixed_uint16_array, EmptyFixedUint16Array) \ |
| 148 V(FixedTypedArrayBase, empty_fixed_int16_array, EmptyFixedInt16Array) \ | 135 V(FixedTypedArrayBase, empty_fixed_int16_array, EmptyFixedInt16Array) \ |
| 149 V(FixedTypedArrayBase, empty_fixed_uint32_array, EmptyFixedUint32Array) \ | 136 V(FixedTypedArrayBase, empty_fixed_uint32_array, EmptyFixedUint32Array) \ |
| 150 V(FixedTypedArrayBase, empty_fixed_int32_array, EmptyFixedInt32Array) \ | 137 V(FixedTypedArrayBase, empty_fixed_int32_array, EmptyFixedInt32Array) \ |
| 151 V(FixedTypedArrayBase, empty_fixed_float32_array, EmptyFixedFloat32Array) \ | 138 V(FixedTypedArrayBase, empty_fixed_float32_array, EmptyFixedFloat32Array) \ |
| 152 V(FixedTypedArrayBase, empty_fixed_float64_array, EmptyFixedFloat64Array) \ | 139 V(FixedTypedArrayBase, empty_fixed_float64_array, EmptyFixedFloat64Array) \ |
| 153 V(FixedTypedArrayBase, empty_fixed_uint8_clamped_array, \ | 140 V(FixedTypedArrayBase, empty_fixed_uint8_clamped_array, \ |
| 154 EmptyFixedUint8ClampedArray) \ | 141 EmptyFixedUint8ClampedArray) \ |
| 155 V(Map, sloppy_arguments_elements_map, SloppyArgumentsElementsMap) \ | 142 V(Map, sloppy_arguments_elements_map, SloppyArgumentsElementsMap) \ |
| 156 V(Map, function_context_map, FunctionContextMap) \ | 143 V(Map, function_context_map, FunctionContextMap) \ |
| 157 V(Map, catch_context_map, CatchContextMap) \ | 144 V(Map, catch_context_map, CatchContextMap) \ |
| 158 V(Map, with_context_map, WithContextMap) \ | 145 V(Map, with_context_map, WithContextMap) \ |
| 159 V(Map, block_context_map, BlockContextMap) \ | 146 V(Map, block_context_map, BlockContextMap) \ |
| 160 V(Map, module_context_map, ModuleContextMap) \ | 147 V(Map, module_context_map, ModuleContextMap) \ |
| 161 V(Map, global_context_map, GlobalContextMap) \ | 148 V(Map, global_context_map, GlobalContextMap) \ |
| 162 V(Map, undefined_map, UndefinedMap) \ | 149 V(Map, undefined_map, UndefinedMap) \ |
| 163 V(Map, the_hole_map, TheHoleMap) \ | 150 V(Map, the_hole_map, TheHoleMap) \ |
| 164 V(Map, null_map, NullMap) \ | 151 V(Map, null_map, NullMap) \ |
| (...skipping 19 matching lines...) Expand all Loading... |
| 184 V(Script, empty_script, EmptyScript) \ | 171 V(Script, empty_script, EmptyScript) \ |
| 185 V(NameDictionary, intrinsic_function_names, IntrinsicFunctionNames) \ | 172 V(NameDictionary, intrinsic_function_names, IntrinsicFunctionNames) \ |
| 186 V(Cell, undefined_cell, UndefineCell) \ | 173 V(Cell, undefined_cell, UndefineCell) \ |
| 187 V(JSObject, observation_state, ObservationState) \ | 174 V(JSObject, observation_state, ObservationState) \ |
| 188 V(Map, external_map, ExternalMap) \ | 175 V(Map, external_map, ExternalMap) \ |
| 189 V(Object, symbol_registry, SymbolRegistry) \ | 176 V(Object, symbol_registry, SymbolRegistry) \ |
| 190 V(Symbol, frozen_symbol, FrozenSymbol) \ | 177 V(Symbol, frozen_symbol, FrozenSymbol) \ |
| 191 V(Symbol, nonexistent_symbol, NonExistentSymbol) \ | 178 V(Symbol, nonexistent_symbol, NonExistentSymbol) \ |
| 192 V(Symbol, elements_transition_symbol, ElementsTransitionSymbol) \ | 179 V(Symbol, elements_transition_symbol, ElementsTransitionSymbol) \ |
| 193 V(SeededNumberDictionary, empty_slow_element_dictionary, \ | 180 V(SeededNumberDictionary, empty_slow_element_dictionary, \ |
| 194 EmptySlowElementDictionary) \ | 181 EmptySlowElementDictionary) \ |
| 195 V(Symbol, observed_symbol, ObservedSymbol) \ | 182 V(Symbol, observed_symbol, ObservedSymbol) \ |
| 196 V(Symbol, uninitialized_symbol, UninitializedSymbol) \ | 183 V(Symbol, uninitialized_symbol, UninitializedSymbol) \ |
| 197 V(Symbol, megamorphic_symbol, MegamorphicSymbol) \ | 184 V(Symbol, megamorphic_symbol, MegamorphicSymbol) \ |
| 198 V(Symbol, stack_trace_symbol, StackTraceSymbol) \ | 185 V(Symbol, stack_trace_symbol, StackTraceSymbol) \ |
| 199 V(Symbol, detailed_stack_trace_symbol, DetailedStackTraceSymbol) \ | 186 V(Symbol, detailed_stack_trace_symbol, DetailedStackTraceSymbol) \ |
| 187 V(Symbol, normal_ic_symbol, NormalICSymbol) \ |
| 200 V(FixedArray, materialized_objects, MaterializedObjects) \ | 188 V(FixedArray, materialized_objects, MaterializedObjects) \ |
| 201 V(FixedArray, allocation_sites_scratchpad, AllocationSitesScratchpad) \ | 189 V(FixedArray, allocation_sites_scratchpad, AllocationSitesScratchpad) \ |
| 202 V(FixedArray, microtask_queue, MicrotaskQueue) | 190 V(FixedArray, microtask_queue, MicrotaskQueue) |
| 203 | 191 |
| 204 // Entries in this list are limited to Smis and are not visited during GC. | 192 // Entries in this list are limited to Smis and are not visited during GC. |
| 205 #define SMI_ROOT_LIST(V) \ | 193 #define SMI_ROOT_LIST(V) \ |
| 206 V(Smi, stack_limit, StackLimit) \ | 194 V(Smi, stack_limit, StackLimit) \ |
| 207 V(Smi, real_stack_limit, RealStackLimit) \ | 195 V(Smi, real_stack_limit, RealStackLimit) \ |
| 208 V(Smi, last_script_id, LastScriptId) \ | 196 V(Smi, last_script_id, LastScriptId) \ |
| 209 V(Smi, arguments_adaptor_deopt_pc_offset, ArgumentsAdaptorDeoptPCOffset) \ | 197 V(Smi, arguments_adaptor_deopt_pc_offset, ArgumentsAdaptorDeoptPCOffset) \ |
| (...skipping 2441 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2651 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. | 2639 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. |
| 2652 | 2640 |
| 2653 private: | 2641 private: |
| 2654 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); | 2642 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); |
| 2655 }; | 2643 }; |
| 2656 #endif // DEBUG | 2644 #endif // DEBUG |
| 2657 | 2645 |
| 2658 } } // namespace v8::internal | 2646 } } // namespace v8::internal |
| 2659 | 2647 |
| 2660 #endif // V8_HEAP_H_ | 2648 #endif // V8_HEAP_H_ |
| OLD | NEW |