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

Unified Diff: src/interpreter/bytecode-register-optimizer.cc

Issue 2041913002: [interpreter] Remove OperandScale from front stages of pipeline. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/interpreter/bytecode-pipeline.cc ('k') | src/interpreter/bytecode-traits.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/interpreter/bytecode-register-optimizer.cc
diff --git a/src/interpreter/bytecode-register-optimizer.cc b/src/interpreter/bytecode-register-optimizer.cc
index 1903247f157bed7bf73281e3fee1237e1a34a89f..ff5f5d0441d86e2911c57888315d902d38f1150e 100644
--- a/src/interpreter/bytecode-register-optimizer.cc
+++ b/src/interpreter/bytecode-register-optimizer.cc
@@ -324,20 +324,16 @@ void BytecodeRegisterOptimizer::OutputRegisterTransfer(
if (input == accumulator_) {
uint32_t operand = static_cast<uint32_t>(output.ToOperand());
- OperandScale scale = Bytecodes::OperandSizesToScale(output.SizeOfOperand());
- BytecodeNode node(Bytecode::kStar, operand, scale);
+ BytecodeNode node(Bytecode::kStar, operand);
WriteToNextStage(&node, source_info);
} else if (output == accumulator_) {
uint32_t operand = static_cast<uint32_t>(input.ToOperand());
- OperandScale scale = Bytecodes::OperandSizesToScale(input.SizeOfOperand());
- BytecodeNode node(Bytecode::kLdar, operand, scale);
+ BytecodeNode node(Bytecode::kLdar, operand);
WriteToNextStage(&node, source_info);
} else {
uint32_t operand0 = static_cast<uint32_t>(input.ToOperand());
uint32_t operand1 = static_cast<uint32_t>(output.ToOperand());
- OperandScale scale = Bytecodes::OperandSizesToScale(input.SizeOfOperand(),
- output.SizeOfOperand());
- BytecodeNode node(Bytecode::kMov, operand0, operand1, scale);
+ BytecodeNode node(Bytecode::kMov, operand0, operand1);
WriteToNextStage(&node, source_info);
}
output_info->set_materialized(true);
@@ -483,12 +479,6 @@ void BytecodeRegisterOptimizer::PrepareRegisterInputOperand(
Register equivalent = GetEquivalentRegisterForInputOperand(reg);
node->operands()[operand_index] =
static_cast<uint32_t>(equivalent.ToOperand());
- // Update operand scale as equivalent may be different.
- OperandScale operand_scale =
- Bytecodes::OperandSizesToScale(equivalent.SizeOfOperand());
- if (operand_scale > node->operand_scale()) {
- node->set_operand_scale(operand_scale);
- }
}
void BytecodeRegisterOptimizer::PrepareRegisterRangeInputOperand(Register start,
« no previous file with comments | « src/interpreter/bytecode-pipeline.cc ('k') | src/interpreter/bytecode-traits.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698