Index: src/compiler/effect-control-linearizer.cc |
diff --git a/src/compiler/effect-control-linearizer.cc b/src/compiler/effect-control-linearizer.cc |
index ba381919298d1ccaa04366baac37e4714ac19058..1304e5410439f757d7e89e45e477aaaecf902036 100644 |
--- a/src/compiler/effect-control-linearizer.cc |
+++ b/src/compiler/effect-control-linearizer.cc |
@@ -434,6 +434,9 @@ bool EffectControlLinearizer::TryWireInStateEffect(Node* node, |
case IrOpcode::kCheckNumber: |
state = LowerCheckNumber(node, frame_state, *effect, *control); |
break; |
+ case IrOpcode::kCheckIf: |
+ state = LowerCheckIf(node, frame_state, *effect, *control); |
+ break; |
case IrOpcode::kCheckTaggedPointer: |
state = LowerCheckTaggedPointer(node, frame_state, *effect, *control); |
break; |
@@ -836,6 +839,20 @@ EffectControlLinearizer::LowerCheckNumber(Node* node, Node* frame_state, |
} |
EffectControlLinearizer::ValueEffectControl |
+EffectControlLinearizer::LowerCheckIf(Node* node, Node* frame_state, |
+ Node* effect, Node* control) { |
+ Node* value = node->InputAt(0); |
+ |
+ control = effect = graph()->NewNode(common()->DeoptimizeUnless(), value, |
+ frame_state, effect, control); |
+ |
+ // Make sure the lowered node does not appear in any use lists. |
+ node->TrimInputCount(0); |
+ |
+ return ValueEffectControl(value, effect, control); |
+} |
+ |
+EffectControlLinearizer::ValueEffectControl |
EffectControlLinearizer::LowerCheckTaggedPointer(Node* node, Node* frame_state, |
Node* effect, Node* control) { |
Node* value = node->InputAt(0); |