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 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
172 V(DERIVED_GET_TRAP_INDEX, JSFunction, derived_get_trap) \ | 172 V(DERIVED_GET_TRAP_INDEX, JSFunction, derived_get_trap) \ |
173 V(DERIVED_SET_TRAP_INDEX, JSFunction, derived_set_trap) \ | 173 V(DERIVED_SET_TRAP_INDEX, JSFunction, derived_set_trap) \ |
174 V(PROXY_ENUMERATE_INDEX, JSFunction, proxy_enumerate) \ | 174 V(PROXY_ENUMERATE_INDEX, JSFunction, proxy_enumerate) \ |
175 V(OBSERVERS_NOTIFY_CHANGE_INDEX, JSFunction, observers_notify_change) \ | 175 V(OBSERVERS_NOTIFY_CHANGE_INDEX, JSFunction, observers_notify_change) \ |
176 V(OBSERVERS_DELIVER_CHANGES_INDEX, JSFunction, observers_deliver_changes) \ | 176 V(OBSERVERS_DELIVER_CHANGES_INDEX, JSFunction, observers_deliver_changes) \ |
177 V(GENERATOR_FUNCTION_MAP_INDEX, Map, generator_function_map) \ | 177 V(GENERATOR_FUNCTION_MAP_INDEX, Map, generator_function_map) \ |
178 V(STRICT_MODE_GENERATOR_FUNCTION_MAP_INDEX, Map, \ | 178 V(STRICT_MODE_GENERATOR_FUNCTION_MAP_INDEX, Map, \ |
179 strict_mode_generator_function_map) \ | 179 strict_mode_generator_function_map) \ |
180 V(GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX, Map, \ | 180 V(GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX, Map, \ |
181 generator_object_prototype_map) \ | 181 generator_object_prototype_map) \ |
| 182 V(GENERATOR_RESULT_MAP_INDEX, Map, generator_result_map) \ |
182 V(RANDOM_SEED_INDEX, ByteArray, random_seed) | 183 V(RANDOM_SEED_INDEX, ByteArray, random_seed) |
183 | 184 |
184 // JSFunctions are pairs (context, function code), sometimes also called | 185 // JSFunctions are pairs (context, function code), sometimes also called |
185 // closures. A Context object is used to represent function contexts and | 186 // closures. A Context object is used to represent function contexts and |
186 // dynamically pushed 'with' contexts (or 'scopes' in ECMA-262 speak). | 187 // dynamically pushed 'with' contexts (or 'scopes' in ECMA-262 speak). |
187 // | 188 // |
188 // At runtime, the contexts build a stack in parallel to the execution | 189 // At runtime, the contexts build a stack in parallel to the execution |
189 // stack, with the top-most context being the current context. All contexts | 190 // stack, with the top-most context being the current context. All contexts |
190 // have the following slots: | 191 // have the following slots: |
191 // | 192 // |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
314 TO_COMPLETE_PROPERTY_DESCRIPTOR_INDEX, | 315 TO_COMPLETE_PROPERTY_DESCRIPTOR_INDEX, |
315 DERIVED_HAS_TRAP_INDEX, | 316 DERIVED_HAS_TRAP_INDEX, |
316 DERIVED_GET_TRAP_INDEX, | 317 DERIVED_GET_TRAP_INDEX, |
317 DERIVED_SET_TRAP_INDEX, | 318 DERIVED_SET_TRAP_INDEX, |
318 PROXY_ENUMERATE_INDEX, | 319 PROXY_ENUMERATE_INDEX, |
319 OBSERVERS_NOTIFY_CHANGE_INDEX, | 320 OBSERVERS_NOTIFY_CHANGE_INDEX, |
320 OBSERVERS_DELIVER_CHANGES_INDEX, | 321 OBSERVERS_DELIVER_CHANGES_INDEX, |
321 GENERATOR_FUNCTION_MAP_INDEX, | 322 GENERATOR_FUNCTION_MAP_INDEX, |
322 STRICT_MODE_GENERATOR_FUNCTION_MAP_INDEX, | 323 STRICT_MODE_GENERATOR_FUNCTION_MAP_INDEX, |
323 GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX, | 324 GENERATOR_OBJECT_PROTOTYPE_MAP_INDEX, |
| 325 GENERATOR_RESULT_MAP_INDEX, |
324 RANDOM_SEED_INDEX, | 326 RANDOM_SEED_INDEX, |
325 | 327 |
326 // Properties from here are treated as weak references by the full GC. | 328 // Properties from here are treated as weak references by the full GC. |
327 // Scavenge treats them as strong references. | 329 // Scavenge treats them as strong references. |
328 OPTIMIZED_FUNCTIONS_LIST, // Weak. | 330 OPTIMIZED_FUNCTIONS_LIST, // Weak. |
329 MAP_CACHE_INDEX, // Weak. | 331 MAP_CACHE_INDEX, // Weak. |
330 NEXT_CONTEXT_LINK, // Weak. | 332 NEXT_CONTEXT_LINK, // Weak. |
331 | 333 |
332 // Total number of slots. | 334 // Total number of slots. |
333 NATIVE_CONTEXT_SLOTS, | 335 NATIVE_CONTEXT_SLOTS, |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
496 static bool IsBootstrappingOrGlobalObject(Object* object); | 498 static bool IsBootstrappingOrGlobalObject(Object* object); |
497 #endif | 499 #endif |
498 | 500 |
499 STATIC_CHECK(kHeaderSize == Internals::kContextHeaderSize); | 501 STATIC_CHECK(kHeaderSize == Internals::kContextHeaderSize); |
500 STATIC_CHECK(EMBEDDER_DATA_INDEX == Internals::kContextEmbedderDataIndex); | 502 STATIC_CHECK(EMBEDDER_DATA_INDEX == Internals::kContextEmbedderDataIndex); |
501 }; | 503 }; |
502 | 504 |
503 } } // namespace v8::internal | 505 } } // namespace v8::internal |
504 | 506 |
505 #endif // V8_CONTEXTS_H_ | 507 #endif // V8_CONTEXTS_H_ |
OLD | NEW |