summaryrefslogtreecommitdiff
path: root/deps/v8/src/interpreter/bytecode-peephole-optimizer.cc
diff options
context:
space:
mode:
Diffstat (limited to 'deps/v8/src/interpreter/bytecode-peephole-optimizer.cc')
-rw-r--r--deps/v8/src/interpreter/bytecode-peephole-optimizer.cc16
1 files changed, 8 insertions, 8 deletions
diff --git a/deps/v8/src/interpreter/bytecode-peephole-optimizer.cc b/deps/v8/src/interpreter/bytecode-peephole-optimizer.cc
index 11aebb6ddb..c87d31c39f 100644
--- a/deps/v8/src/interpreter/bytecode-peephole-optimizer.cc
+++ b/deps/v8/src/interpreter/bytecode-peephole-optimizer.cc
@@ -13,17 +13,17 @@ namespace interpreter {
BytecodePeepholeOptimizer::BytecodePeepholeOptimizer(
BytecodePipelineStage* next_stage)
- : next_stage_(next_stage) {
+ : next_stage_(next_stage), last_(Bytecode::kIllegal) {
InvalidateLast();
}
// override
Handle<BytecodeArray> BytecodePeepholeOptimizer::ToBytecodeArray(
- Isolate* isolate, int fixed_register_count, int parameter_count,
+ Isolate* isolate, int register_count, int parameter_count,
Handle<FixedArray> handler_table) {
Flush();
- return next_stage_->ToBytecodeArray(isolate, fixed_register_count,
- parameter_count, handler_table);
+ return next_stage_->ToBytecodeArray(isolate, register_count, parameter_count,
+ handler_table);
}
// override
@@ -142,7 +142,7 @@ void TransformLdaSmiBinaryOpToBinaryOpWithSmi(Bytecode new_bytecode,
current->set_bytecode(new_bytecode, last->operand(0), current->operand(0),
current->operand(1));
if (last->source_info().is_valid()) {
- current->source_info().Clone(last->source_info());
+ current->source_info_ptr()->Clone(last->source_info());
}
}
@@ -153,7 +153,7 @@ void TransformLdaZeroBinaryOpToBinaryOpWithZero(Bytecode new_bytecode,
current->set_bytecode(new_bytecode, 0, current->operand(0),
current->operand(1));
if (last->source_info().is_valid()) {
- current->source_info().Clone(last->source_info());
+ current->source_info_ptr()->Clone(last->source_info());
}
}
@@ -223,7 +223,7 @@ void BytecodePeepholeOptimizer::ElideLastAction(
// |node| can not have a valid source position if the source
// position of last() is valid (per rules in
// CanElideLastBasedOnSourcePosition()).
- node->source_info().Clone(last()->source_info());
+ node->source_info_ptr()->Clone(last()->source_info());
}
SetLast(node);
} else {
@@ -314,7 +314,7 @@ void BytecodePeepholeOptimizer::ElideLastBeforeJumpAction(
if (!CanElideLastBasedOnSourcePosition(node)) {
next_stage()->Write(last());
} else if (!node->source_info().is_valid()) {
- node->source_info().Clone(last()->source_info());
+ node->source_info_ptr()->Clone(last()->source_info());
}
InvalidateLast();
}