Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/code-stub-assembler.h" | 5 #include "src/code-stub-assembler.h" |
| 6 | 6 |
| 7 namespace v8 { | 7 namespace v8 { |
| 8 namespace internal { | 8 namespace internal { |
| 9 | 9 |
| 10 typedef compiler::Node Node; | 10 typedef compiler::Node Node; |
| 11 typedef CodeStubAssembler::ParameterMode ParameterMode; | 11 typedef CodeStubAssembler::ParameterMode ParameterMode; |
| 12 typedef compiler::CodeAssemblerState CodeAssemblerState; | 12 typedef compiler::CodeAssemblerState CodeAssemblerState; |
| 13 | 13 |
| 14 class PromiseBuiltinsAssembler : public CodeStubAssembler { | 14 class PromiseBuiltinsAssembler : public CodeStubAssembler { |
| 15 public: | 15 public: |
| 16 explicit PromiseBuiltinsAssembler(CodeAssemblerState* state) | 16 explicit PromiseBuiltinsAssembler(CodeAssemblerState* state) |
| 17 : CodeStubAssembler(state) {} | 17 : CodeStubAssembler(state) {} |
| 18 | 18 |
| 19 Node* AllocateAndInitPromise(Node* context, Node* parent); | 19 // These are just wrapper functions over the CSA counterparts and |
| 20 // call out to the init promise hook. | |
|
adamk
2017/01/03 18:23:06
This is really a question for caitp, I think, but
caitp
2017/01/03 18:32:05
I'm not sure if there are any situations where we'
| |
| 21 Node* AllocateAndInitJSPromise(Node* context, Node* parent); | |
| 22 Node* AllocateAndSetJSPromise(Node* context, Node* status, Node* result, | |
| 23 Node* parent); | |
| 20 | 24 |
| 21 Node* ThrowIfNotJSReceiver(Node* context, Node* value, | 25 Node* ThrowIfNotJSReceiver(Node* context, Node* value, |
| 22 MessageTemplate::Template msg_template); | 26 MessageTemplate::Template msg_template); |
| 23 | 27 |
| 24 Node* SpeciesConstructor(Node* context, Node* object, | 28 Node* SpeciesConstructor(Node* context, Node* object, |
| 25 Node* default_constructor); | 29 Node* default_constructor); |
| 26 | 30 |
| 27 Node* PromiseHasHandler(Node* promise); | 31 Node* PromiseHasHandler(Node* promise); |
| 28 | 32 |
| 29 void PromiseSetHasHandler(Node* promise); | 33 void PromiseSetHasHandler(Node* promise); |
| (...skipping 17 matching lines...) Expand all Loading... | |
| 47 | 51 |
| 48 Node* CreatePromiseResolvingFunctionsContext(Node* promise, Node* debug_event, | 52 Node* CreatePromiseResolvingFunctionsContext(Node* promise, Node* debug_event, |
| 49 Node* native_context); | 53 Node* native_context); |
| 50 | 54 |
| 51 std::pair<Node*, Node*> CreatePromiseResolvingFunctions( | 55 std::pair<Node*, Node*> CreatePromiseResolvingFunctions( |
| 52 Node* promise, Node* native_context, Node* promise_context); | 56 Node* promise, Node* native_context, Node* promise_context); |
| 53 }; | 57 }; |
| 54 | 58 |
| 55 } // namespace internal | 59 } // namespace internal |
| 56 } // namespace v8 | 60 } // namespace v8 |
| OLD | NEW |