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

Side by Side Diff: src/arm64/lithium-arm64.h

Issue 295913009: Allow specifying base offset when constructing Keyed hydrogen instructions (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Remove more unnecessary code Created 6 years, 7 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
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/arm64/lithium-codegen-arm64.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 #ifndef V8_ARM64_LITHIUM_ARM64_H_ 5 #ifndef V8_ARM64_LITHIUM_ARM64_H_
6 #define V8_ARM64_LITHIUM_ARM64_H_ 6 #define V8_ARM64_LITHIUM_ARM64_H_
7 7
8 #include "hydrogen.h" 8 #include "hydrogen.h"
9 #include "lithium-allocator.h" 9 #include "lithium-allocator.h"
10 #include "lithium.h" 10 #include "lithium.h"
(...skipping 1739 matching lines...) Expand 10 before | Expand all | Expand 10 after
1750 } 1750 }
1751 bool is_external() const { 1751 bool is_external() const {
1752 return this->hydrogen()->is_external(); 1752 return this->hydrogen()->is_external();
1753 } 1753 }
1754 bool is_fixed_typed_array() const { 1754 bool is_fixed_typed_array() const {
1755 return hydrogen()->is_fixed_typed_array(); 1755 return hydrogen()->is_fixed_typed_array();
1756 } 1756 }
1757 bool is_typed_elements() const { 1757 bool is_typed_elements() const {
1758 return is_external() || is_fixed_typed_array(); 1758 return is_external() || is_fixed_typed_array();
1759 } 1759 }
1760 uint32_t additional_index() const { 1760 uint32_t base_offset() const {
1761 return this->hydrogen()->index_offset(); 1761 return this->hydrogen()->base_offset();
1762 } 1762 }
1763 void PrintDataTo(StringStream* stream) V8_OVERRIDE { 1763 void PrintDataTo(StringStream* stream) V8_OVERRIDE {
1764 this->elements()->PrintTo(stream); 1764 this->elements()->PrintTo(stream);
1765 stream->Add("["); 1765 stream->Add("[");
1766 this->key()->PrintTo(stream); 1766 this->key()->PrintTo(stream);
1767 if (this->hydrogen()->IsDehoisted()) { 1767 if (this->base_offset() != 0) {
1768 stream->Add(" + %d]", this->additional_index()); 1768 stream->Add(" + %d]", this->base_offset());
1769 } else { 1769 } else {
1770 stream->Add("]"); 1770 stream->Add("]");
1771 } 1771 }
1772 } 1772 }
1773 1773
1774 DECLARE_HYDROGEN_ACCESSOR(LoadKeyed) 1774 DECLARE_HYDROGEN_ACCESSOR(LoadKeyed)
1775 }; 1775 };
1776 1776
1777 1777
1778 class LLoadKeyedExternal: public LLoadKeyed<1> { 1778 class LLoadKeyedExternal: public LLoadKeyed<1> {
(...skipping 633 matching lines...) Expand 10 before | Expand all | Expand 10 after
2412 return this->hydrogen()->elements_kind(); 2412 return this->hydrogen()->elements_kind();
2413 } 2413 }
2414 2414
2415 bool NeedsCanonicalization() { 2415 bool NeedsCanonicalization() {
2416 if (hydrogen()->value()->IsAdd() || hydrogen()->value()->IsSub() || 2416 if (hydrogen()->value()->IsAdd() || hydrogen()->value()->IsSub() ||
2417 hydrogen()->value()->IsMul() || hydrogen()->value()->IsDiv()) { 2417 hydrogen()->value()->IsMul() || hydrogen()->value()->IsDiv()) {
2418 return false; 2418 return false;
2419 } 2419 }
2420 return this->hydrogen()->NeedsCanonicalization(); 2420 return this->hydrogen()->NeedsCanonicalization();
2421 } 2421 }
2422 uint32_t additional_index() const { return this->hydrogen()->index_offset(); } 2422 uint32_t base_offset() const { return this->hydrogen()->base_offset(); }
2423 2423
2424 void PrintDataTo(StringStream* stream) V8_OVERRIDE { 2424 void PrintDataTo(StringStream* stream) V8_OVERRIDE {
2425 this->elements()->PrintTo(stream); 2425 this->elements()->PrintTo(stream);
2426 stream->Add("["); 2426 stream->Add("[");
2427 this->key()->PrintTo(stream); 2427 this->key()->PrintTo(stream);
2428 if (this->hydrogen()->IsDehoisted()) { 2428 if (this->base_offset() != 0) {
2429 stream->Add(" + %d] <-", this->additional_index()); 2429 stream->Add(" + %d] <-", this->base_offset());
2430 } else { 2430 } else {
2431 stream->Add("] <- "); 2431 stream->Add("] <- ");
2432 } 2432 }
2433 2433
2434 if (this->value() == NULL) { 2434 if (this->value() == NULL) {
2435 ASSERT(hydrogen()->IsConstantHoleStore() && 2435 ASSERT(hydrogen()->IsConstantHoleStore() &&
2436 hydrogen()->value()->representation().IsDouble()); 2436 hydrogen()->value()->representation().IsDouble());
2437 stream->Add("<the hole(nan)>"); 2437 stream->Add("<the hole(nan)>");
2438 } else { 2438 } else {
2439 this->value()->PrintTo(stream); 2439 this->value()->PrintTo(stream);
(...skipping 748 matching lines...) Expand 10 before | Expand all | Expand 10 after
3188 3188
3189 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 3189 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
3190 }; 3190 };
3191 3191
3192 #undef DECLARE_HYDROGEN_ACCESSOR 3192 #undef DECLARE_HYDROGEN_ACCESSOR
3193 #undef DECLARE_CONCRETE_INSTRUCTION 3193 #undef DECLARE_CONCRETE_INSTRUCTION
3194 3194
3195 } } // namespace v8::internal 3195 } } // namespace v8::internal
3196 3196
3197 #endif // V8_ARM64_LITHIUM_ARM64_H_ 3197 #endif // V8_ARM64_LITHIUM_ARM64_H_
OLDNEW
« no previous file with comments | « src/arm/lithium-codegen-arm.cc ('k') | src/arm64/lithium-codegen-arm64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698