Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: src/runtime.cc

Issue 331633002: Revert "Revert "Reland 21774: Generate KeyedLoadGeneric with Hydrogen"" (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #include <stdlib.h> 5 #include <stdlib.h>
6 #include <limits> 6 #include <limits>
7 7
8 #include "src/v8.h" 8 #include "src/v8.h"
9 9
10 #include "src/accessors.h" 10 #include "src/accessors.h"
(...skipping 5542 matching lines...) Expand 10 before | Expand all | Expand 10 after
5553 boilerplate_object->GetElementsKind(), 5553 boilerplate_object->GetElementsKind(),
5554 transitioned_kind)) { 5554 transitioned_kind)) {
5555 JSObject::TransitionElementsKind(boilerplate_object, transitioned_kind); 5555 JSObject::TransitionElementsKind(boilerplate_object, transitioned_kind);
5556 } 5556 }
5557 JSObject::TransitionElementsKind(object, transitioned_kind); 5557 JSObject::TransitionElementsKind(object, transitioned_kind);
5558 ASSERT(IsFastDoubleElementsKind(object->GetElementsKind())); 5558 ASSERT(IsFastDoubleElementsKind(object->GetElementsKind()));
5559 FixedDoubleArray* double_array = FixedDoubleArray::cast(object->elements()); 5559 FixedDoubleArray* double_array = FixedDoubleArray::cast(object->elements());
5560 HeapNumber* number = HeapNumber::cast(*value); 5560 HeapNumber* number = HeapNumber::cast(*value);
5561 double_array->set(store_index, number->Number()); 5561 double_array->set(store_index, number->Number());
5562 } else { 5562 } else {
5563 ASSERT(IsFastSmiElementsKind(elements_kind) || 5563 if (!IsFastObjectElementsKind(elements_kind)) {
5564 IsFastDoubleElementsKind(elements_kind)); 5564 ElementsKind transitioned_kind = IsFastHoleyElementsKind(elements_kind)
5565 ElementsKind transitioned_kind = IsFastHoleyElementsKind(elements_kind) 5565 ? FAST_HOLEY_ELEMENTS
5566 ? FAST_HOLEY_ELEMENTS 5566 : FAST_ELEMENTS;
5567 : FAST_ELEMENTS; 5567 JSObject::TransitionElementsKind(object, transitioned_kind);
5568 JSObject::TransitionElementsKind(object, transitioned_kind); 5568 ElementsKind boilerplate_elements_kind =
5569 if (IsMoreGeneralElementsKindTransition( 5569 boilerplate_object->GetElementsKind();
5570 boilerplate_object->GetElementsKind(), 5570 if (IsMoreGeneralElementsKindTransition(boilerplate_elements_kind,
5571 transitioned_kind)) { 5571 transitioned_kind)) {
5572 JSObject::TransitionElementsKind(boilerplate_object, transitioned_kind); 5572 JSObject::TransitionElementsKind(boilerplate_object, transitioned_kind);
5573 }
5573 } 5574 }
5574 FixedArray* object_array = FixedArray::cast(object->elements()); 5575 FixedArray* object_array = FixedArray::cast(object->elements());
5575 object_array->set(store_index, *value); 5576 object_array->set(store_index, *value);
5576 } 5577 }
5577 return *object; 5578 return *object;
5578 } 5579 }
5579 5580
5580 5581
5581 // Check whether debugger and is about to step into the callback that is passed 5582 // Check whether debugger and is about to step into the callback that is passed
5582 // to a built-in function such as Array.forEach. 5583 // to a built-in function such as Array.forEach.
(...skipping 9618 matching lines...) Expand 10 before | Expand all | Expand 10 after
15201 } 15202 }
15202 return NULL; 15203 return NULL;
15203 } 15204 }
15204 15205
15205 15206
15206 const Runtime::Function* Runtime::FunctionForId(Runtime::FunctionId id) { 15207 const Runtime::Function* Runtime::FunctionForId(Runtime::FunctionId id) {
15207 return &(kIntrinsicFunctions[static_cast<int>(id)]); 15208 return &(kIntrinsicFunctions[static_cast<int>(id)]);
15208 } 15209 }
15209 15210
15210 } } // namespace v8::internal 15211 } } // namespace v8::internal
OLDNEW
« src/objects.h ('K') | « src/objects.h ('k') | src/serialize.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698