Index: src/compiler/js-intrinsic-lowering.cc |
diff --git a/src/compiler/js-intrinsic-lowering.cc b/src/compiler/js-intrinsic-lowering.cc |
index 9a1fe0a8b6fa4e4e12b8dde28101c1b96cc40b92..28e4c27db5af5675d85bf59dc1eb2fa5b7bd128b 100644 |
--- a/src/compiler/js-intrinsic-lowering.cc |
+++ b/src/compiler/js-intrinsic-lowering.cc |
@@ -40,6 +40,8 @@ Reduction JSIntrinsicLowering::Reduce(Node* node) { |
return ReduceGeneratorClose(node); |
case Runtime::kInlineGeneratorGetInputOrDebugPos: |
return ReduceGeneratorGetInputOrDebugPos(node); |
+ case Runtime::kInlineAsyncGeneratorGetAwaitInput: |
+ return ReduceAsyncGeneratorGetAwaitInput(node); |
case Runtime::kInlineGeneratorGetResumeMode: |
return ReduceGeneratorGetResumeMode(node); |
case Runtime::kInlineIsArray: |
@@ -140,6 +142,31 @@ Reduction JSIntrinsicLowering::ReduceGeneratorGetInputOrDebugPos(Node* node) { |
return Change(node, op, generator, effect, control); |
} |
+Reduction JSIntrinsicLowering::ReduceAsyncGeneratorGetAwaitInput(Node* node) { |
+ Node* const generator = NodeProperties::GetValueInput(node, 0); |
+ Node* const effect = NodeProperties::GetEffectInput(node); |
+ Node* const control = NodeProperties::GetControlInput(node); |
+ Operator const* const op = simplified()->LoadField( |
+ AccessBuilder::ForJSAsyncGeneratorObjectAwaitInput()); |
+ |
+ return Change(node, op, generator, effect, control); |
+} |
+ |
+Reduction JSIntrinsicLowering::ReduceGeneratorSaveInputForAwait(Node* node) { |
+ Node* const generator = NodeProperties::GetValueInput(node, 0); |
+ Node* const effect = NodeProperties::GetEffectInput(node); |
+ Node* const control = NodeProperties::GetControlInput(node); |
+ |
+ Node* const input = graph()->NewNode( |
+ simplified()->LoadField( |
+ AccessBuilder::ForJSAsyncGeneratorObjectAwaitInput()), |
+ generator, effect, control); |
+ |
+ Operator const* const op = simplified()->StoreField( |
+ AccessBuilder::ForJSGeneratorObjectContinuation()); |
+ return Change(node, op, generator, input, effect, control); |
+} |
+ |
Reduction JSIntrinsicLowering::ReduceGeneratorGetResumeMode(Node* node) { |
Node* const generator = NodeProperties::GetValueInput(node, 0); |
Node* const effect = NodeProperties::GetEffectInput(node); |