OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 V(Map, cons_symbol_map, ConsSymbolMap) \ | 82 V(Map, cons_symbol_map, ConsSymbolMap) \ |
83 V(Map, cons_ascii_symbol_map, ConsAsciiSymbolMap) \ | 83 V(Map, cons_ascii_symbol_map, ConsAsciiSymbolMap) \ |
84 V(Map, external_symbol_map, ExternalSymbolMap) \ | 84 V(Map, external_symbol_map, ExternalSymbolMap) \ |
85 V(Map, external_symbol_with_ascii_data_map, ExternalSymbolWithAsciiDataMap) \ | 85 V(Map, external_symbol_with_ascii_data_map, ExternalSymbolWithAsciiDataMap) \ |
86 V(Map, external_ascii_symbol_map, ExternalAsciiSymbolMap) \ | 86 V(Map, external_ascii_symbol_map, ExternalAsciiSymbolMap) \ |
87 V(Map, external_string_map, ExternalStringMap) \ | 87 V(Map, external_string_map, ExternalStringMap) \ |
88 V(Map, external_string_with_ascii_data_map, ExternalStringWithAsciiDataMap) \ | 88 V(Map, external_string_with_ascii_data_map, ExternalStringWithAsciiDataMap) \ |
89 V(Map, external_ascii_string_map, ExternalAsciiStringMap) \ | 89 V(Map, external_ascii_string_map, ExternalAsciiStringMap) \ |
90 V(Map, undetectable_string_map, UndetectableStringMap) \ | 90 V(Map, undetectable_string_map, UndetectableStringMap) \ |
91 V(Map, undetectable_ascii_string_map, UndetectableAsciiStringMap) \ | 91 V(Map, undetectable_ascii_string_map, UndetectableAsciiStringMap) \ |
92 V(Map, pixel_array_map, PixelArrayMap) \ | 92 V(Map, external_pixel_array_map, ExternalPixelArrayMap) \ |
93 V(Map, external_byte_array_map, ExternalByteArrayMap) \ | 93 V(Map, external_byte_array_map, ExternalByteArrayMap) \ |
94 V(Map, external_unsigned_byte_array_map, ExternalUnsignedByteArrayMap) \ | 94 V(Map, external_unsigned_byte_array_map, ExternalUnsignedByteArrayMap) \ |
95 V(Map, external_short_array_map, ExternalShortArrayMap) \ | 95 V(Map, external_short_array_map, ExternalShortArrayMap) \ |
96 V(Map, external_unsigned_short_array_map, ExternalUnsignedShortArrayMap) \ | 96 V(Map, external_unsigned_short_array_map, ExternalUnsignedShortArrayMap) \ |
97 V(Map, external_int_array_map, ExternalIntArrayMap) \ | 97 V(Map, external_int_array_map, ExternalIntArrayMap) \ |
98 V(Map, external_unsigned_int_array_map, ExternalUnsignedIntArrayMap) \ | 98 V(Map, external_unsigned_int_array_map, ExternalUnsignedIntArrayMap) \ |
99 V(Map, external_float_array_map, ExternalFloatArrayMap) \ | 99 V(Map, external_float_array_map, ExternalFloatArrayMap) \ |
100 V(Map, context_map, ContextMap) \ | 100 V(Map, context_map, ContextMap) \ |
101 V(Map, catch_context_map, CatchContextMap) \ | 101 V(Map, catch_context_map, CatchContextMap) \ |
102 V(Map, code_map, CodeMap) \ | 102 V(Map, code_map, CodeMap) \ |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
178 V(Date_symbol, "Date") \ | 178 V(Date_symbol, "Date") \ |
179 V(this_symbol, "this") \ | 179 V(this_symbol, "this") \ |
180 V(to_string_symbol, "toString") \ | 180 V(to_string_symbol, "toString") \ |
181 V(char_at_symbol, "CharAt") \ | 181 V(char_at_symbol, "CharAt") \ |
182 V(undefined_symbol, "undefined") \ | 182 V(undefined_symbol, "undefined") \ |
183 V(value_of_symbol, "valueOf") \ | 183 V(value_of_symbol, "valueOf") \ |
184 V(InitializeVarGlobal_symbol, "InitializeVarGlobal") \ | 184 V(InitializeVarGlobal_symbol, "InitializeVarGlobal") \ |
185 V(InitializeConstGlobal_symbol, "InitializeConstGlobal") \ | 185 V(InitializeConstGlobal_symbol, "InitializeConstGlobal") \ |
186 V(KeyedLoadSpecialized_symbol, "KeyedLoadSpecialized") \ | 186 V(KeyedLoadSpecialized_symbol, "KeyedLoadSpecialized") \ |
187 V(KeyedStoreSpecialized_symbol, "KeyedStoreSpecialized") \ | 187 V(KeyedStoreSpecialized_symbol, "KeyedStoreSpecialized") \ |
188 V(KeyedLoadPixelArray_symbol, "KeyedLoadPixelArray") \ | |
189 V(KeyedStorePixelArray_symbol, "KeyedStorePixelArray") \ | |
190 V(stack_overflow_symbol, "kStackOverflowBoilerplate") \ | 188 V(stack_overflow_symbol, "kStackOverflowBoilerplate") \ |
191 V(illegal_access_symbol, "illegal access") \ | 189 V(illegal_access_symbol, "illegal access") \ |
192 V(out_of_memory_symbol, "out-of-memory") \ | 190 V(out_of_memory_symbol, "out-of-memory") \ |
193 V(illegal_execution_state_symbol, "illegal execution state") \ | 191 V(illegal_execution_state_symbol, "illegal execution state") \ |
194 V(get_symbol, "get") \ | 192 V(get_symbol, "get") \ |
195 V(set_symbol, "set") \ | 193 V(set_symbol, "set") \ |
196 V(function_class_symbol, "Function") \ | 194 V(function_class_symbol, "Function") \ |
197 V(illegal_argument_symbol, "illegal argument") \ | 195 V(illegal_argument_symbol, "illegal argument") \ |
198 V(MakeReferenceError_symbol, "MakeReferenceError") \ | 196 V(MakeReferenceError_symbol, "MakeReferenceError") \ |
199 V(MakeSyntaxError_symbol, "MakeSyntaxError") \ | 197 V(MakeSyntaxError_symbol, "MakeSyntaxError") \ |
200 V(MakeTypeError_symbol, "MakeTypeError") \ | 198 V(MakeTypeError_symbol, "MakeTypeError") \ |
201 V(invalid_lhs_in_assignment_symbol, "invalid_lhs_in_assignment") \ | 199 V(invalid_lhs_in_assignment_symbol, "invalid_lhs_in_assignment") \ |
202 V(invalid_lhs_in_for_in_symbol, "invalid_lhs_in_for_in") \ | 200 V(invalid_lhs_in_for_in_symbol, "invalid_lhs_in_for_in") \ |
203 V(invalid_lhs_in_postfix_op_symbol, "invalid_lhs_in_postfix_op") \ | 201 V(invalid_lhs_in_postfix_op_symbol, "invalid_lhs_in_postfix_op") \ |
204 V(invalid_lhs_in_prefix_op_symbol, "invalid_lhs_in_prefix_op") \ | 202 V(invalid_lhs_in_prefix_op_symbol, "invalid_lhs_in_prefix_op") \ |
205 V(illegal_return_symbol, "illegal_return") \ | 203 V(illegal_return_symbol, "illegal_return") \ |
206 V(illegal_break_symbol, "illegal_break") \ | 204 V(illegal_break_symbol, "illegal_break") \ |
207 V(illegal_continue_symbol, "illegal_continue") \ | 205 V(illegal_continue_symbol, "illegal_continue") \ |
208 V(unknown_label_symbol, "unknown_label") \ | 206 V(unknown_label_symbol, "unknown_label") \ |
209 V(redeclaration_symbol, "redeclaration") \ | 207 V(redeclaration_symbol, "redeclaration") \ |
210 V(failure_symbol, "<failure>") \ | 208 V(failure_symbol, "<failure>") \ |
211 V(space_symbol, " ") \ | 209 V(space_symbol, " ") \ |
212 V(exec_symbol, "exec") \ | 210 V(exec_symbol, "exec") \ |
213 V(zero_symbol, "0") \ | 211 V(zero_symbol, "0") \ |
214 V(global_eval_symbol, "GlobalEval") \ | 212 V(global_eval_symbol, "GlobalEval") \ |
215 V(identity_hash_symbol, "v8::IdentityHash") \ | 213 V(identity_hash_symbol, "v8::IdentityHash") \ |
216 V(closure_symbol, "(closure)") \ | 214 V(closure_symbol, "(closure)") \ |
217 V(use_strict, "use strict") \ | 215 V(use_strict, "use strict") \ |
218 V(KeyedLoadExternalArray_symbol, "KeyedLoadExternalArray") \ | 216 V(KeyedLoadExternalByteArray_symbol, "KeyedLoadExternalByteArray") \ |
219 V(KeyedStoreExternalArray_symbol, "KeyedStoreExternalArray") | 217 V(KeyedLoadExternalUnsignedByteArray_symbol, \ |
| 218 "KeyedLoadExternalUnsignedByteArray") \ |
| 219 V(KeyedLoadExternalShortArray_symbol, \ |
| 220 "KeyedLoadExternalShortArray") \ |
| 221 V(KeyedLoadExternalUnsignedShortArray_symbol, \ |
| 222 "KeyedLoadExternalUnsignedShortArray") \ |
| 223 V(KeyedLoadExternalIntArray_symbol, "KeyedLoadExternalIntArray") \ |
| 224 V(KeyedLoadExternalUnsignedIntArray_symbol, \ |
| 225 "KeyedLoadExternalUnsignedIntArray") \ |
| 226 V(KeyedLoadExternalFloatArray_symbol, "KeyedLoadExternalFloatArray") \ |
| 227 V(KeyedLoadExternalPixelArray_symbol, "KeyedLoadExternalPixelArray") \ |
| 228 V(KeyedStoreExternalByteArray_symbol, "KeyedStoreExternalByteArray") \ |
| 229 V(KeyedStoreExternalUnsignedByteArray_symbol, \ |
| 230 "KeyedStoreExternalUnsignedByteArray") \ |
| 231 V(KeyedStoreExternalShortArray_symbol, "KeyedStoreExternalShortArray") \ |
| 232 V(KeyedStoreExternalUnsignedShortArray_symbol, \ |
| 233 "KeyedStoreExternalUnsignedShortArray") \ |
| 234 V(KeyedStoreExternalIntArray_symbol, "KeyedStoreExternalIntArray") \ |
| 235 V(KeyedStoreExternalUnsignedIntArray_symbol, \ |
| 236 "KeyedStoreExternalUnsignedIntArray") \ |
| 237 V(KeyedStoreExternalFloatArray_symbol, "KeyedStoreExternalFloatArray") \ |
| 238 V(KeyedStoreExternalPixelArray_symbol, "KeyedStoreExternalPixelArray") |
220 | 239 |
221 // Forward declarations. | 240 // Forward declarations. |
222 class GCTracer; | 241 class GCTracer; |
223 class HeapStats; | 242 class HeapStats; |
224 class WeakObjectRetainer; | 243 class WeakObjectRetainer; |
225 | 244 |
226 | 245 |
227 typedef String* (*ExternalStringTableUpdaterCallback)(Object** pointer); | 246 typedef String* (*ExternalStringTableUpdaterCallback)(Object** pointer); |
228 | 247 |
229 typedef bool (*DirtyRegionCallback)(Address start, | 248 typedef bool (*DirtyRegionCallback)(Address start, |
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
491 // Allocate a non-tenured byte array of the specified length | 510 // Allocate a non-tenured byte array of the specified length |
492 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation | 511 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation |
493 // failed. | 512 // failed. |
494 // Please note this does not perform a garbage collection. | 513 // Please note this does not perform a garbage collection. |
495 MUST_USE_RESULT static MaybeObject* AllocateByteArray(int length); | 514 MUST_USE_RESULT static MaybeObject* AllocateByteArray(int length); |
496 | 515 |
497 // Allocate a pixel array of the specified length | 516 // Allocate a pixel array of the specified length |
498 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation | 517 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation |
499 // failed. | 518 // failed. |
500 // Please note this does not perform a garbage collection. | 519 // Please note this does not perform a garbage collection. |
501 MUST_USE_RESULT static MaybeObject* AllocatePixelArray(int length, | 520 MUST_USE_RESULT static MaybeObject* AllocateExternalPixelArray( |
502 uint8_t* external_pointer, | 521 int length, |
503 PretenureFlag pretenure); | 522 uint8_t* external_pointer, |
| 523 PretenureFlag pretenure); |
504 | 524 |
505 // Allocates an external array of the specified length and type. | 525 // Allocates an external array of the specified length and type. |
506 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation | 526 // Returns Failure::RetryAfterGC(requested_bytes, space) if the allocation |
507 // failed. | 527 // failed. |
508 // Please note this does not perform a garbage collection. | 528 // Please note this does not perform a garbage collection. |
509 MUST_USE_RESULT static MaybeObject* AllocateExternalArray( | 529 MUST_USE_RESULT static MaybeObject* AllocateExternalArray( |
510 int length, | 530 int length, |
511 ExternalArrayType array_type, | 531 ExternalArrayType array_type, |
512 void* external_pointer, | 532 void* external_pointer, |
513 PretenureFlag pretenure); | 533 PretenureFlag pretenure); |
(...skipping 1694 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2208 AssertNoAllocation no_alloc; // i.e. no gc allowed. | 2228 AssertNoAllocation no_alloc; // i.e. no gc allowed. |
2209 | 2229 |
2210 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); | 2230 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); |
2211 }; | 2231 }; |
2212 #endif // DEBUG || LIVE_OBJECT_LIST | 2232 #endif // DEBUG || LIVE_OBJECT_LIST |
2213 | 2233 |
2214 | 2234 |
2215 } } // namespace v8::internal | 2235 } } // namespace v8::internal |
2216 | 2236 |
2217 #endif // V8_HEAP_H_ | 2237 #endif // V8_HEAP_H_ |
OLD | NEW |