Commit e6e3c6a8 authored by oth's avatar oth Committed by Commit bot

[Interpreter] Remove unnecessary const specifiers on scalar types.

BUG=v8:4280
LOG=N

Review URL: https://codereview.chromium.org/1269813006

Cr-Commit-Position: refs/heads/master@{#29961}
parent 11eb702e
......@@ -52,7 +52,7 @@ Bytecode Bytecodes::FromByte(uint8_t value) {
// static
const int Bytecodes::NumberOfOperands(Bytecode bytecode) {
int Bytecodes::NumberOfOperands(Bytecode bytecode) {
DCHECK(bytecode <= Bytecode::kLast);
int count;
uint8_t row = ToByte(bytecode);
......@@ -66,24 +66,24 @@ const int Bytecodes::NumberOfOperands(Bytecode bytecode) {
// static
const OperandType Bytecodes::GetOperandType(Bytecode bytecode, int i) {
OperandType Bytecodes::GetOperandType(Bytecode bytecode, int i) {
DCHECK(bytecode <= Bytecode::kLast && i < NumberOfOperands(bytecode));
return kBytecodeTable[ToByte(bytecode)][i];
}
// static
const int Bytecodes::Size(Bytecode bytecode) {
int Bytecodes::Size(Bytecode bytecode) {
return 1 + NumberOfOperands(bytecode);
}
// static
const int Bytecodes::MaximumNumberOfOperands() { return kMaxOperands; }
int Bytecodes::MaximumNumberOfOperands() { return kMaxOperands; }
// static
const int Bytecodes::MaximumSize() { return 1 + kMaxOperands; }
int Bytecodes::MaximumSize() { return 1 + kMaxOperands; }
std::ostream& operator<<(std::ostream& os, const Bytecode& bytecode) {
......
......@@ -66,19 +66,19 @@ class Bytecodes {
static Bytecode FromByte(uint8_t value);
// Returns the number of operands expected by |bytecode|.
static const int NumberOfOperands(Bytecode bytecode);
static int NumberOfOperands(Bytecode bytecode);
// Return the i-th operand of |bytecode|.
static const OperandType GetOperandType(Bytecode bytecode, int i);
static OperandType GetOperandType(Bytecode bytecode, int i);
// Returns the size of the bytecode including its arguments.
static const int Size(Bytecode bytecode);
static int Size(Bytecode bytecode);
// The maximum number of operands across all bytecodes.
static const int MaximumNumberOfOperands();
static int MaximumNumberOfOperands();
// Maximum size of a bytecode and its arguments.
static const int MaximumSize();
static int MaximumSize();
private:
DISALLOW_IMPLICIT_CONSTRUCTORS(Bytecodes);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment