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_CONTEXTS_H_ | 5 #ifndef V8_CONTEXTS_H_ |
6 #define V8_CONTEXTS_H_ | 6 #define V8_CONTEXTS_H_ |
7 | 7 |
8 #include "src/heap/heap.h" | 8 #include "src/heap/heap.h" |
9 #include "src/objects.h" | 9 #include "src/objects.h" |
10 | 10 |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 V(INITIAL_OBJECT_PROTOTYPE_INDEX, JSObject, initial_object_prototype) \ | 91 V(INITIAL_OBJECT_PROTOTYPE_INDEX, JSObject, initial_object_prototype) \ |
92 V(INITIAL_ARRAY_PROTOTYPE_INDEX, JSObject, initial_array_prototype) \ | 92 V(INITIAL_ARRAY_PROTOTYPE_INDEX, JSObject, initial_array_prototype) \ |
93 V(CREATE_DATE_FUN_INDEX, JSFunction, create_date_fun) \ | 93 V(CREATE_DATE_FUN_INDEX, JSFunction, create_date_fun) \ |
94 V(TO_NUMBER_FUN_INDEX, JSFunction, to_number_fun) \ | 94 V(TO_NUMBER_FUN_INDEX, JSFunction, to_number_fun) \ |
95 V(TO_STRING_FUN_INDEX, JSFunction, to_string_fun) \ | 95 V(TO_STRING_FUN_INDEX, JSFunction, to_string_fun) \ |
96 V(TO_DETAIL_STRING_FUN_INDEX, JSFunction, to_detail_string_fun) \ | 96 V(TO_DETAIL_STRING_FUN_INDEX, JSFunction, to_detail_string_fun) \ |
97 V(TO_OBJECT_FUN_INDEX, JSFunction, to_object_fun) \ | 97 V(TO_OBJECT_FUN_INDEX, JSFunction, to_object_fun) \ |
98 V(TO_INTEGER_FUN_INDEX, JSFunction, to_integer_fun) \ | 98 V(TO_INTEGER_FUN_INDEX, JSFunction, to_integer_fun) \ |
99 V(TO_UINT32_FUN_INDEX, JSFunction, to_uint32_fun) \ | 99 V(TO_UINT32_FUN_INDEX, JSFunction, to_uint32_fun) \ |
100 V(TO_INT32_FUN_INDEX, JSFunction, to_int32_fun) \ | 100 V(TO_INT32_FUN_INDEX, JSFunction, to_int32_fun) \ |
| 101 V(TO_LENGTH_FUN_INDEX, JSFunction, to_length_fun) \ |
101 V(GLOBAL_EVAL_FUN_INDEX, JSFunction, global_eval_fun) \ | 102 V(GLOBAL_EVAL_FUN_INDEX, JSFunction, global_eval_fun) \ |
102 V(INSTANTIATE_FUN_INDEX, JSFunction, instantiate_fun) \ | 103 V(INSTANTIATE_FUN_INDEX, JSFunction, instantiate_fun) \ |
103 V(CONFIGURE_INSTANCE_FUN_INDEX, JSFunction, configure_instance_fun) \ | 104 V(CONFIGURE_INSTANCE_FUN_INDEX, JSFunction, configure_instance_fun) \ |
104 V(ARRAY_BUFFER_FUN_INDEX, JSFunction, array_buffer_fun) \ | 105 V(ARRAY_BUFFER_FUN_INDEX, JSFunction, array_buffer_fun) \ |
105 V(UINT8_ARRAY_FUN_INDEX, JSFunction, uint8_array_fun) \ | 106 V(UINT8_ARRAY_FUN_INDEX, JSFunction, uint8_array_fun) \ |
106 V(INT8_ARRAY_FUN_INDEX, JSFunction, int8_array_fun) \ | 107 V(INT8_ARRAY_FUN_INDEX, JSFunction, int8_array_fun) \ |
107 V(UINT16_ARRAY_FUN_INDEX, JSFunction, uint16_array_fun) \ | 108 V(UINT16_ARRAY_FUN_INDEX, JSFunction, uint16_array_fun) \ |
108 V(INT16_ARRAY_FUN_INDEX, JSFunction, int16_array_fun) \ | 109 V(INT16_ARRAY_FUN_INDEX, JSFunction, int16_array_fun) \ |
109 V(UINT32_ARRAY_FUN_INDEX, JSFunction, uint32_array_fun) \ | 110 V(UINT32_ARRAY_FUN_INDEX, JSFunction, uint32_array_fun) \ |
110 V(INT32_ARRAY_FUN_INDEX, JSFunction, int32_array_fun) \ | 111 V(INT32_ARRAY_FUN_INDEX, JSFunction, int32_array_fun) \ |
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
409 NATIVE_OBJECT_NOTIFIER_PERFORM_CHANGE, | 410 NATIVE_OBJECT_NOTIFIER_PERFORM_CHANGE, |
410 SLOPPY_GENERATOR_FUNCTION_MAP_INDEX, | 411 SLOPPY_GENERATOR_FUNCTION_MAP_INDEX, |
411 STRICT_GENERATOR_FUNCTION_MAP_INDEX, | 412 STRICT_GENERATOR_FUNCTION_MAP_INDEX, |
412 GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX, | 413 GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX, |
413 ITERATOR_RESULT_MAP_INDEX, | 414 ITERATOR_RESULT_MAP_INDEX, |
414 MAP_ITERATOR_MAP_INDEX, | 415 MAP_ITERATOR_MAP_INDEX, |
415 SET_ITERATOR_MAP_INDEX, | 416 SET_ITERATOR_MAP_INDEX, |
416 ARRAY_VALUES_ITERATOR_INDEX, | 417 ARRAY_VALUES_ITERATOR_INDEX, |
417 SCRIPT_CONTEXT_TABLE_INDEX, | 418 SCRIPT_CONTEXT_TABLE_INDEX, |
418 MAP_CACHE_INDEX, | 419 MAP_CACHE_INDEX, |
| 420 TO_LENGTH_FUN_INDEX, |
419 | 421 |
420 // Properties from here are treated as weak references by the full GC. | 422 // Properties from here are treated as weak references by the full GC. |
421 // Scavenge treats them as strong references. | 423 // Scavenge treats them as strong references. |
422 OPTIMIZED_FUNCTIONS_LIST, // Weak. | 424 OPTIMIZED_FUNCTIONS_LIST, // Weak. |
423 OPTIMIZED_CODE_LIST, // Weak. | 425 OPTIMIZED_CODE_LIST, // Weak. |
424 DEOPTIMIZED_CODE_LIST, // Weak. | 426 DEOPTIMIZED_CODE_LIST, // Weak. |
425 NEXT_CONTEXT_LINK, // Weak. | 427 NEXT_CONTEXT_LINK, // Weak. |
426 | 428 |
427 // Total number of slots. | 429 // Total number of slots. |
428 NATIVE_CONTEXT_SLOTS, | 430 NATIVE_CONTEXT_SLOTS, |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
607 static bool IsBootstrappingOrGlobalObject(Isolate* isolate, Object* object); | 609 static bool IsBootstrappingOrGlobalObject(Isolate* isolate, Object* object); |
608 #endif | 610 #endif |
609 | 611 |
610 STATIC_ASSERT(kHeaderSize == Internals::kContextHeaderSize); | 612 STATIC_ASSERT(kHeaderSize == Internals::kContextHeaderSize); |
611 STATIC_ASSERT(EMBEDDER_DATA_INDEX == Internals::kContextEmbedderDataIndex); | 613 STATIC_ASSERT(EMBEDDER_DATA_INDEX == Internals::kContextEmbedderDataIndex); |
612 }; | 614 }; |
613 | 615 |
614 } } // namespace v8::internal | 616 } } // namespace v8::internal |
615 | 617 |
616 #endif // V8_CONTEXTS_H_ | 618 #endif // V8_CONTEXTS_H_ |
OLD | NEW |