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

Side by Side Diff: src/code-stubs-hydrogen.cc

Issue 391693002: In-object double fields unboxing (for 64-bit only). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 5 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 "src/v8.h" 5 #include "src/v8.h"
6 6
7 #include "src/code-stubs.h" 7 #include "src/code-stubs.h"
8 #include "src/field-index.h" 8 #include "src/field-index.h"
9 #include "src/hydrogen.h" 9 #include "src/hydrogen.h"
10 #include "src/lithium.h" 10 #include "src/lithium.h"
(...skipping 545 matching lines...) Expand 10 before | Expand all | Expand 10 after
556 556
557 HLoadNamedField* CodeStubGraphBuilderBase::BuildLoadNamedField( 557 HLoadNamedField* CodeStubGraphBuilderBase::BuildLoadNamedField(
558 HValue* object, FieldIndex index) { 558 HValue* object, FieldIndex index) {
559 Representation representation = index.is_double() 559 Representation representation = index.is_double()
560 ? Representation::Double() 560 ? Representation::Double()
561 : Representation::Tagged(); 561 : Representation::Tagged();
562 int offset = index.offset(); 562 int offset = index.offset();
563 HObjectAccess access = index.is_inobject() 563 HObjectAccess access = index.is_inobject()
564 ? HObjectAccess::ForObservableJSObjectOffset(offset, representation) 564 ? HObjectAccess::ForObservableJSObjectOffset(offset, representation)
565 : HObjectAccess::ForBackingStoreOffset(offset, representation); 565 : HObjectAccess::ForBackingStoreOffset(offset, representation);
566 if (index.is_double()) { 566 if (index.is_double() &&
567 (!FLAG_unbox_double_fields || !index.is_inobject())) {
567 // Load the heap number. 568 // Load the heap number.
568 object = Add<HLoadNamedField>( 569 object = Add<HLoadNamedField>(
569 object, static_cast<HValue*>(NULL), 570 object, static_cast<HValue*>(NULL),
570 access.WithRepresentation(Representation::Tagged())); 571 access.WithRepresentation(Representation::Tagged()));
571 // Load the double value from it. 572 // Load the double value from it.
572 access = HObjectAccess::ForHeapNumberValue(); 573 access = HObjectAccess::ForHeapNumberValue();
573 } 574 }
574 return Add<HLoadNamedField>(object, static_cast<HValue*>(NULL), access); 575 return Add<HLoadNamedField>(object, static_cast<HValue*>(NULL), access);
575 } 576 }
576 577
(...skipping 1148 matching lines...) Expand 10 before | Expand all | Expand 10 after
1725 return Pop(); 1726 return Pop();
1726 } 1727 }
1727 1728
1728 1729
1729 Handle<Code> KeyedLoadGenericElementStub::GenerateCode() { 1730 Handle<Code> KeyedLoadGenericElementStub::GenerateCode() {
1730 return DoGenerateCode(this); 1731 return DoGenerateCode(this);
1731 } 1732 }
1732 1733
1733 1734
1734 } } // namespace v8::internal 1735 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/bootstrapper.cc ('k') | src/field-index.h » ('j') | src/heap.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698