OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 #include "src/lookup.h" | 5 #include "src/lookup.h" |
6 | 6 |
7 #include "src/bootstrapper.h" | 7 #include "src/bootstrapper.h" |
8 #include "src/deoptimizer.h" | 8 #include "src/deoptimizer.h" |
9 #include "src/elements.h" | 9 #include "src/elements.h" |
10 #include "src/field-type.h" | 10 #include "src/field-type.h" |
(...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
345 if (IsElement()) { | 345 if (IsElement()) { |
346 Handle<JSObject> object = Handle<JSObject>::cast(holder); | 346 Handle<JSObject> object = Handle<JSObject>::cast(holder); |
347 ElementsAccessor* accessor = object->GetElementsAccessor(); | 347 ElementsAccessor* accessor = object->GetElementsAccessor(); |
348 accessor->Delete(object, number_); | 348 accessor->Delete(object, number_); |
349 } else { | 349 } else { |
350 bool is_prototype_map = holder->map()->is_prototype_map(); | 350 bool is_prototype_map = holder->map()->is_prototype_map(); |
351 RuntimeCallTimerScope stats_scope( | 351 RuntimeCallTimerScope stats_scope( |
352 isolate_, is_prototype_map | 352 isolate_, is_prototype_map |
353 ? &RuntimeCallStats::PrototypeObject_DeleteProperty | 353 ? &RuntimeCallStats::PrototypeObject_DeleteProperty |
354 : &RuntimeCallStats::Object_DeleteProperty); | 354 : &RuntimeCallStats::Object_DeleteProperty); |
| 355 TRACE_RUNTIME_CALL(is_prototype_map ? "PrototypeObject_DeleteProperty" |
| 356 : "Object_DeleteProperty"); |
355 | 357 |
356 PropertyNormalizationMode mode = | 358 PropertyNormalizationMode mode = |
357 is_prototype_map ? KEEP_INOBJECT_PROPERTIES : CLEAR_INOBJECT_PROPERTIES; | 359 is_prototype_map ? KEEP_INOBJECT_PROPERTIES : CLEAR_INOBJECT_PROPERTIES; |
358 | 360 |
359 if (holder->HasFastProperties()) { | 361 if (holder->HasFastProperties()) { |
360 JSObject::NormalizeProperties(Handle<JSObject>::cast(holder), mode, 0, | 362 JSObject::NormalizeProperties(Handle<JSObject>::cast(holder), mode, 0, |
361 "DeletingProperty"); | 363 "DeletingProperty"); |
362 ReloadPropertyInformation<false>(); | 364 ReloadPropertyInformation<false>(); |
363 } | 365 } |
364 // TODO(verwaest): Get rid of the name_ argument. | 366 // TODO(verwaest): Get rid of the name_ argument. |
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
752 case v8::internal::kAccessor: | 754 case v8::internal::kAccessor: |
753 return ACCESSOR; | 755 return ACCESSOR; |
754 } | 756 } |
755 | 757 |
756 UNREACHABLE(); | 758 UNREACHABLE(); |
757 return state_; | 759 return state_; |
758 } | 760 } |
759 | 761 |
760 } // namespace internal | 762 } // namespace internal |
761 } // namespace v8 | 763 } // namespace v8 |
OLD | NEW |