Revert of [Interpreter] Rename GetCountOperand to GetRegisterCountOperand. (patchset #1 id:20001 of https://codereview.chromium.org/1691433002/ )
Reason for revert: [Sheriff] Breaks the tree: https://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20builder/builds/13892 Blamelists are wrong because of overloaded master. The trybots on this CL might have been outdated by the time of commit... Please rebase and retry. Original issue's description: > [Interpreter] Rename GetCountOperand to GetRegisterCountOperand. > > Apparently, this BytecodeArrayIterator method was missed during the > previous refactor. No other (collateral) change was done. > > BUG=v8:4280 > LOG=N > > Committed: https://crrev.com/3781ca79f5c48b55d7f0bf6df370ec11515a1466 > Cr-Commit-Position: refs/heads/master@{#33897} TBR=oth@chromium.org,rmcilroy@chromium.org,mstarzinger@chromium.org,ssanfilippo@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=v8:4280 Review URL: https://codereview.chromium.org/1690963002 Cr-Commit-Position: refs/heads/master@{#33900}
This commit is contained in:
parent
3a2fbc3a4e
commit
4e95426ae6
@ -1050,7 +1050,7 @@ void BytecodeGraphBuilder::BuildCall() {
|
||||
Node* callee =
|
||||
environment()->LookupRegister(bytecode_iterator().GetRegisterOperand(0));
|
||||
interpreter::Register receiver = bytecode_iterator().GetRegisterOperand(1);
|
||||
size_t arg_count = bytecode_iterator().GetRegisterCountOperand(2);
|
||||
size_t arg_count = bytecode_iterator().GetCountOperand(2);
|
||||
VectorSlotPair feedback =
|
||||
CreateVectorSlotPair(bytecode_iterator().GetIndexOperand(3));
|
||||
|
||||
@ -1070,7 +1070,7 @@ void BytecodeGraphBuilder::BuildCallJSRuntime() {
|
||||
Node* callee =
|
||||
BuildLoadNativeContextField(bytecode_iterator().GetIndexOperand(0));
|
||||
interpreter::Register receiver = bytecode_iterator().GetRegisterOperand(1);
|
||||
size_t arg_count = bytecode_iterator().GetRegisterCountOperand(2);
|
||||
size_t arg_count = bytecode_iterator().GetCountOperand(2);
|
||||
|
||||
// Create node to perform the JS runtime call.
|
||||
const Operator* call =
|
||||
@ -1101,7 +1101,7 @@ void BytecodeGraphBuilder::BuildCallRuntime() {
|
||||
Runtime::FunctionId functionId =
|
||||
static_cast<Runtime::FunctionId>(bytecode_iterator().GetIndexOperand(0));
|
||||
interpreter::Register first_arg = bytecode_iterator().GetRegisterOperand(1);
|
||||
size_t arg_count = bytecode_iterator().GetRegisterCountOperand(2);
|
||||
size_t arg_count = bytecode_iterator().GetCountOperand(2);
|
||||
|
||||
// Create node to perform the runtime call.
|
||||
const Operator* call = javascript()->CallRuntime(functionId, arg_count);
|
||||
@ -1118,7 +1118,7 @@ void BytecodeGraphBuilder::BuildCallRuntimeForPair() {
|
||||
Runtime::FunctionId functionId =
|
||||
static_cast<Runtime::FunctionId>(bytecode_iterator().GetIndexOperand(0));
|
||||
interpreter::Register first_arg = bytecode_iterator().GetRegisterOperand(1);
|
||||
size_t arg_count = bytecode_iterator().GetRegisterCountOperand(2);
|
||||
size_t arg_count = bytecode_iterator().GetCountOperand(2);
|
||||
interpreter::Register first_return =
|
||||
bytecode_iterator().GetRegisterOperand(3);
|
||||
|
||||
@ -1157,7 +1157,7 @@ void BytecodeGraphBuilder::BuildCallConstruct() {
|
||||
FrameStateBeforeAndAfter states(this);
|
||||
interpreter::Register callee = bytecode_iterator().GetRegisterOperand(0);
|
||||
interpreter::Register first_arg = bytecode_iterator().GetRegisterOperand(1);
|
||||
size_t arg_count = bytecode_iterator().GetRegisterCountOperand(2);
|
||||
size_t arg_count = bytecode_iterator().GetCountOperand(2);
|
||||
|
||||
// TODO(turbofan): Pass the feedback here.
|
||||
const Operator* call = javascript()->CallConstruct(
|
||||
|
@ -63,7 +63,8 @@ int8_t BytecodeArrayIterator::GetImmediateOperand(int operand_index) const {
|
||||
return static_cast<int8_t>(operand);
|
||||
}
|
||||
|
||||
int BytecodeArrayIterator::GetRegisterCountOperand(int operand_index) const {
|
||||
|
||||
int BytecodeArrayIterator::GetCountOperand(int operand_index) const {
|
||||
OperandSize size =
|
||||
Bytecodes::GetOperandSize(current_bytecode(), operand_index);
|
||||
OperandType type = (size == OperandSize::kByte) ? OperandType::kRegCount8
|
||||
@ -130,7 +131,7 @@ int BytecodeArrayIterator::GetRegisterOperandRange(int operand_index) const {
|
||||
OperandType next_operand_type =
|
||||
Bytecodes::GetOperandType(current_bytecode(), operand_index + 1);
|
||||
if (Bytecodes::IsRegisterCountOperandType(next_operand_type)) {
|
||||
return GetRegisterCountOperand(operand_index + 1);
|
||||
return GetCountOperand(operand_index + 1);
|
||||
}
|
||||
}
|
||||
return 1;
|
||||
|
@ -29,7 +29,7 @@ class BytecodeArrayIterator {
|
||||
|
||||
int8_t GetImmediateOperand(int operand_index) const;
|
||||
int GetIndexOperand(int operand_index) const;
|
||||
int GetRegisterCountOperand(int operand_index) const;
|
||||
int GetCountOperand(int operand_index) const;
|
||||
Register GetRegisterOperand(int operand_index) const;
|
||||
int GetRegisterOperandRange(int operand_index) const;
|
||||
Handle<Object> GetConstantForIndexOperand(int operand_index) const;
|
||||
|
@ -95,7 +95,7 @@ TEST_F(BytecodeArrayIteratorTest, IteratesBytecodeArray) {
|
||||
CHECK_EQ(static_cast<Runtime::FunctionId>(iterator.GetIndexOperand(0)),
|
||||
Runtime::kLoadIC_Miss);
|
||||
CHECK_EQ(iterator.GetRegisterOperand(1).index(), reg_0.index());
|
||||
CHECK_EQ(iterator.GetRegisterCountOperand(2), 1);
|
||||
CHECK_EQ(iterator.GetCountOperand(2), 1);
|
||||
CHECK(!iterator.done());
|
||||
iterator.Advance();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user