Index: src/compiler/bytecode-graph-builder.cc |
diff --git a/src/compiler/bytecode-graph-builder.cc b/src/compiler/bytecode-graph-builder.cc |
index ba2247f120c55752d7e484e330f4dff596c85174..56976fda0406665eceac4a088c097ed659924906 100644 |
--- a/src/compiler/bytecode-graph-builder.cc |
+++ b/src/compiler/bytecode-graph-builder.cc |
@@ -1765,6 +1765,21 @@ void BytecodeGraphBuilder::VisitJumpIfUndefinedConstantWide( |
BuildJumpIfEqual(jsgraph()->UndefinedConstant()); |
} |
+void BytecodeGraphBuilder::VisitJumpIfHole( |
+ const interpreter::BytecodeArrayIterator& iterator) { |
+ BuildJumpIfEqual(jsgraph()->TheHoleConstant()); |
+} |
+ |
+void BytecodeGraphBuilder::VisitJumpIfNotHole( |
+ const interpreter::BytecodeArrayIterator& iterator) { |
+ Node* accumulator = environment()->LookupAccumulator(); |
+ Node* condition = NewNode(javascript()->StrictEqual(), accumulator, |
+ jsgraph()->TheHoleConstant()); |
+ Node* node = |
+ NewNode(common()->Select(MachineRepresentation::kTagged), condition, |
+ jsgraph()->FalseConstant(), jsgraph()->TrueConstant()); |
+ BuildConditionalJump(node); |
+} |
void BytecodeGraphBuilder::VisitReturn( |
const interpreter::BytecodeArrayIterator& iterator) { |