| Index: src/interpreter/interpreter.cc
|
| diff --git a/src/interpreter/interpreter.cc b/src/interpreter/interpreter.cc
|
| index 38150c515c7fd441e6cc0049a830ddf5d4a1a056..97397d17d430964efcfc0c10da60a5099d3065dd 100644
|
| --- a/src/interpreter/interpreter.cc
|
| +++ b/src/interpreter/interpreter.cc
|
| @@ -1574,8 +1574,7 @@ void Interpreter::DoJumpIfNullConstantWide(
|
| DoJumpIfNullConstant(assembler);
|
| }
|
|
|
| -
|
| -// jumpifundefined <imm8>
|
| +// JumpIfUndefined <imm8>
|
| //
|
| // Jump by number of bytes represented by an immediate operand if the object
|
| // referenced by the accumulator is the undefined constant.
|
| @@ -1613,6 +1612,31 @@ void Interpreter::DoJumpIfUndefinedConstantWide(
|
| DoJumpIfUndefinedConstant(assembler);
|
| }
|
|
|
| +// JumpIfHole <imm8>
|
| +//
|
| +// Jump by number of bytes represented by an immediate operand if the object
|
| +// referenced by the accumulator is the hole.
|
| +void Interpreter::DoJumpIfHole(compiler::InterpreterAssembler* assembler) {
|
| + Node* accumulator = __ GetAccumulator();
|
| + Node* the_hole_value = __ HeapConstant(isolate_->factory()->the_hole_value());
|
| + Node* relative_jump = __ BytecodeOperandImm(0);
|
| + __ JumpIfWordEqual(accumulator, the_hole_value, relative_jump);
|
| +}
|
| +
|
| +// JumpIfHole <imm8>
|
| +//
|
| +// Jump by number of bytes represented by an immediate operand if the object
|
| +// referenced by the accumulator is not the hole.
|
| +void Interpreter::DoJumpIfNotHole(compiler::InterpreterAssembler* assembler) {
|
| + // TODO(mythria): Implement with wordNotEquals.
|
| + Node* accumulator = __ GetAccumulator();
|
| + Node* the_hole_value = __ HeapConstant(isolate_->factory()->the_hole_value());
|
| + Node* result = __ CallRuntime(Runtime::kInterpreterStrictEquals, accumulator,
|
| + the_hole_value);
|
| + Node* false_value = __ BooleanConstant(false);
|
| + Node* relative_jump = __ BytecodeOperandImm(0);
|
| + __ JumpIfWordEqual(result, false_value, relative_jump);
|
| +}
|
|
|
| void Interpreter::DoCreateLiteral(Runtime::FunctionId function_id,
|
| compiler::InterpreterAssembler* assembler) {
|
|
|