OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 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 185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
196 | 196 |
197 | 197 |
198 void TransformToFastProperties(Handle<JSObject> object, | 198 void TransformToFastProperties(Handle<JSObject> object, |
199 int unused_property_fields) { | 199 int unused_property_fields) { |
200 CALL_HEAP_FUNCTION_VOID( | 200 CALL_HEAP_FUNCTION_VOID( |
201 object->TransformToFastProperties(unused_property_fields)); | 201 object->TransformToFastProperties(unused_property_fields)); |
202 } | 202 } |
203 | 203 |
204 | 204 |
205 void FlattenString(Handle<String> string) { | 205 void FlattenString(Handle<String> string) { |
206 CALL_HEAP_FUNCTION_VOID(string->TryFlattenIfNotFlat()); | 206 CALL_HEAP_FUNCTION_VOID(string->TryFlatten()); |
207 ASSERT(string->IsFlat()); | 207 ASSERT(string->IsFlat()); |
208 } | 208 } |
209 | 209 |
210 | 210 |
211 Handle<Object> SetPrototype(Handle<JSFunction> function, | 211 Handle<Object> SetPrototype(Handle<JSFunction> function, |
212 Handle<Object> prototype) { | 212 Handle<Object> prototype) { |
213 CALL_HEAP_FUNCTION(Accessors::FunctionSetPrototype(*function, | 213 CALL_HEAP_FUNCTION(Accessors::FunctionSetPrototype(*function, |
214 *prototype, | 214 *prototype, |
215 NULL), | 215 NULL), |
216 Object); | 216 Object); |
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
355 CALL_HEAP_FUNCTION(obj->DeleteProperty(*prop, JSObject::NORMAL_DELETION), | 355 CALL_HEAP_FUNCTION(obj->DeleteProperty(*prop, JSObject::NORMAL_DELETION), |
356 Object); | 356 Object); |
357 } | 357 } |
358 | 358 |
359 | 359 |
360 Handle<Object> LookupSingleCharacterStringFromCode(uint32_t index) { | 360 Handle<Object> LookupSingleCharacterStringFromCode(uint32_t index) { |
361 CALL_HEAP_FUNCTION(Heap::LookupSingleCharacterStringFromCode(index), Object); | 361 CALL_HEAP_FUNCTION(Heap::LookupSingleCharacterStringFromCode(index), Object); |
362 } | 362 } |
363 | 363 |
364 | 364 |
365 Handle<String> SubString(Handle<String> str, int start, int end) { | 365 Handle<String> SubString(Handle<String> str, |
366 CALL_HEAP_FUNCTION(str->SubString(start, end), String); | 366 int start, |
| 367 int end, |
| 368 PretenureFlag pretenure) { |
| 369 CALL_HEAP_FUNCTION(str->SubString(start, end, pretenure), String); |
367 } | 370 } |
368 | 371 |
369 | 372 |
370 Handle<Object> SetElement(Handle<JSObject> object, | 373 Handle<Object> SetElement(Handle<JSObject> object, |
371 uint32_t index, | 374 uint32_t index, |
372 Handle<Object> value) { | 375 Handle<Object> value) { |
373 if (object->HasPixelElements() || object->HasExternalArrayElements()) { | 376 if (object->HasPixelElements() || object->HasExternalArrayElements()) { |
374 if (!value->IsSmi() && !value->IsHeapNumber() && !value->IsUndefined()) { | 377 if (!value->IsSmi() && !value->IsHeapNumber() && !value->IsUndefined()) { |
375 bool has_exception; | 378 bool has_exception; |
376 Handle<Object> number = Execution::ToNumber(value, &has_exception); | 379 Handle<Object> number = Execution::ToNumber(value, &has_exception); |
(...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
829 Handle<Map> new_map = Factory::CopyMapDropTransitions(old_map); | 832 Handle<Map> new_map = Factory::CopyMapDropTransitions(old_map); |
830 obj->set_map(*new_map); | 833 obj->set_map(*new_map); |
831 new_map->set_needs_loading(true); | 834 new_map->set_needs_loading(true); |
832 // Store the lazy loading info in the constructor field. We'll | 835 // Store the lazy loading info in the constructor field. We'll |
833 // reestablish the constructor from the fixed array after loading. | 836 // reestablish the constructor from the fixed array after loading. |
834 new_map->set_constructor(*arr); | 837 new_map->set_constructor(*arr); |
835 ASSERT(!obj->IsLoaded()); | 838 ASSERT(!obj->IsLoaded()); |
836 } | 839 } |
837 | 840 |
838 } } // namespace v8::internal | 841 } } // namespace v8::internal |
OLD | NEW |