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

Side by Side Diff: src/compiler/instruction.cc

Issue 1959763002: [turbofan] Rename floating point register / slot methods. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Unfix arm64. Created 4 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
« no previous file with comments | « src/compiler/instruction.h ('k') | src/compiler/mips/code-generator-mips.cc » ('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 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/compiler/common-operator.h" 5 #include "src/compiler/common-operator.h"
6 #include "src/compiler/graph.h" 6 #include "src/compiler/graph.h"
7 #include "src/compiler/instruction.h" 7 #include "src/compiler/instruction.h"
8 #include "src/compiler/schedule.h" 8 #include "src/compiler/schedule.h"
9 #include "src/compiler/state-values-utils.h" 9 #include "src/compiler/state-values-utils.h"
10 10
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 return os << "#" << imm.inline_value(); 120 return os << "#" << imm.inline_value();
121 case ImmediateOperand::INDEXED: 121 case ImmediateOperand::INDEXED:
122 return os << "[immediate:" << imm.indexed_value() << "]"; 122 return os << "[immediate:" << imm.indexed_value() << "]";
123 } 123 }
124 } 124 }
125 case InstructionOperand::EXPLICIT: 125 case InstructionOperand::EXPLICIT:
126 case InstructionOperand::ALLOCATED: { 126 case InstructionOperand::ALLOCATED: {
127 LocationOperand allocated = LocationOperand::cast(op); 127 LocationOperand allocated = LocationOperand::cast(op);
128 if (op.IsStackSlot()) { 128 if (op.IsStackSlot()) {
129 os << "[stack:" << LocationOperand::cast(op).index(); 129 os << "[stack:" << LocationOperand::cast(op).index();
130 } else if (op.IsDoubleStackSlot()) { 130 } else if (op.IsFPStackSlot()) {
131 os << "[double_stack:" << LocationOperand::cast(op).index(); 131 os << "[fp_stack:" << LocationOperand::cast(op).index();
132 } else if (op.IsRegister()) { 132 } else if (op.IsRegister()) {
133 os << "[" << LocationOperand::cast(op).GetRegister().ToString() << "|R"; 133 os << "[" << LocationOperand::cast(op).GetRegister().ToString() << "|R";
134 } else { 134 } else {
135 DCHECK(op.IsDoubleRegister()); 135 DCHECK(op.IsFPRegister());
136 os << "[" << LocationOperand::cast(op).GetDoubleRegister().ToString() 136 os << "[" << LocationOperand::cast(op).GetDoubleRegister().ToString()
137 << "|R"; 137 << "|R";
138 } 138 }
139 if (allocated.IsExplicit()) { 139 if (allocated.IsExplicit()) {
140 os << "|E"; 140 os << "|E";
141 } 141 }
142 switch (allocated.representation()) { 142 switch (allocated.representation()) {
143 case MachineRepresentation::kNone: 143 case MachineRepresentation::kNone:
144 os << "|-"; 144 os << "|-";
145 break; 145 break;
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
328 PrintableMoveOperands pmo = {printable.register_configuration_, move}; 328 PrintableMoveOperands pmo = {printable.register_configuration_, move};
329 os << pmo; 329 os << pmo;
330 } 330 }
331 return os; 331 return os;
332 } 332 }
333 333
334 334
335 void ReferenceMap::RecordReference(const AllocatedOperand& op) { 335 void ReferenceMap::RecordReference(const AllocatedOperand& op) {
336 // Do not record arguments as pointers. 336 // Do not record arguments as pointers.
337 if (op.IsStackSlot() && LocationOperand::cast(op).index() < 0) return; 337 if (op.IsStackSlot() && LocationOperand::cast(op).index() < 0) return;
338 DCHECK(!op.IsDoubleRegister() && !op.IsDoubleStackSlot()); 338 DCHECK(!op.IsFPRegister() && !op.IsFPStackSlot());
339 reference_operands_.push_back(op); 339 reference_operands_.push_back(op);
340 } 340 }
341 341
342 342
343 std::ostream& operator<<(std::ostream& os, const ReferenceMap& pm) { 343 std::ostream& operator<<(std::ostream& os, const ReferenceMap& pm) {
344 os << "{"; 344 os << "{";
345 bool first = true; 345 bool first = true;
346 PrintableInstructionOperand poi = { 346 PrintableInstructionOperand poi = {
347 RegisterConfiguration::ArchDefault(RegisterConfiguration::TURBOFAN), 347 RegisterConfiguration::ArchDefault(RegisterConfiguration::TURBOFAN),
348 InstructionOperand()}; 348 InstructionOperand()};
(...skipping 677 matching lines...) Expand 10 before | Expand all | Expand 10 after
1026 } 1026 }
1027 for (int i = 0; i < code.InstructionBlockCount(); i++) { 1027 for (int i = 0; i < code.InstructionBlockCount(); i++) {
1028 printable.sequence_->PrintBlock(printable.register_configuration_, i); 1028 printable.sequence_->PrintBlock(printable.register_configuration_, i);
1029 } 1029 }
1030 return os; 1030 return os;
1031 } 1031 }
1032 1032
1033 } // namespace compiler 1033 } // namespace compiler
1034 } // namespace internal 1034 } // namespace internal
1035 } // namespace v8 1035 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/instruction.h ('k') | src/compiler/mips/code-generator-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698