Index: src/compiler/js-native-context-specialization.cc |
diff --git a/src/compiler/js-native-context-specialization.cc b/src/compiler/js-native-context-specialization.cc |
index 4ff5632372d80021b0c70f76650acfb1b38c1147..9df4d533a1ff03dab31f9fcb62dacb06f3ba81d7 100644 |
--- a/src/compiler/js-native-context-specialization.cc |
+++ b/src/compiler/js-native-context-specialization.cc |
@@ -9,6 +9,7 @@ |
#include "src/compilation-dependencies.h" |
#include "src/compiler/access-builder.h" |
#include "src/compiler/access-info.h" |
+#include "src/compiler/frame-states.h" |
#include "src/compiler/js-graph.h" |
#include "src/compiler/js-operator.h" |
#include "src/compiler/linkage.h" |
@@ -166,6 +167,7 @@ Reduction JSNativeContextSpecialization::ReduceJSInstanceOf(Node* node) { |
Node* constructor = NodeProperties::GetValueInput(node, 1); |
Node* context = NodeProperties::GetContextInput(node); |
Node* effect = NodeProperties::GetEffectInput(node); |
+ Node* outer_frame_state = NodeProperties::GetFrameStateInput(node); |
Node* control = NodeProperties::GetControlInput(node); |
// Check if the right hand side is a known {receiver}. |
@@ -235,11 +237,17 @@ Reduction JSNativeContextSpecialization::ReduceJSInstanceOf(Node* node) { |
effect = BuildCheckMaps(constructor, effect, control, |
access_info.receiver_maps()); |
+ Node* frame_state; |
+ std::tie(frame_state, effect) = CreateStubBuiltinContinuationFrameState( |
+ jsgraph(), Builtins::kToBooleanLazyDeoptContinuation, context, nullptr, |
+ 0, effect, control, outer_frame_state, DONT_CREATE_CHECKPOINT); |
+ |
// Call the @@hasInstance handler. |
Node* target = jsgraph()->Constant(constant); |
node->InsertInput(graph()->zone(), 0, target); |
node->ReplaceInput(1, constructor); |
node->ReplaceInput(2, object); |
+ node->ReplaceInput(4, frame_state); |
node->ReplaceInput(5, effect); |
NodeProperties::ChangeOp( |
node, |