Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(693)

Side by Side Diff: src/code-stub-assembler.h

Issue 2604273003: [csa] Refactor promises API (Closed)
Patch Set: rebase Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #ifndef V8_CODE_STUB_ASSEMBLER_H_ 5 #ifndef V8_CODE_STUB_ASSEMBLER_H_
6 #define V8_CODE_STUB_ASSEMBLER_H_ 6 #define V8_CODE_STUB_ASSEMBLER_H_
7 7
8 #include <functional> 8 #include <functional>
9 9
10 #include "src/compiler/code-assembler.h" 10 #include "src/compiler/code-assembler.h"
(...skipping 1109 matching lines...) Expand 10 before | Expand all | Expand 10 after
1120 1120
1121 Node* ElementOffsetFromIndex(Node* index, ElementsKind kind, 1121 Node* ElementOffsetFromIndex(Node* index, ElementsKind kind,
1122 ParameterMode mode, int base_size = 0); 1122 ParameterMode mode, int base_size = 0);
1123 1123
1124 Node* AllocateFunctionWithMapAndContext(Node* map, Node* shared_info, 1124 Node* AllocateFunctionWithMapAndContext(Node* map, Node* shared_info,
1125 Node* context); 1125 Node* context);
1126 1126
1127 // Promise helpers 1127 // Promise helpers
1128 Node* IsPromiseHookEnabled(); 1128 Node* IsPromiseHookEnabled();
1129 1129
1130 Node* AllocateJSPromise(Node* context); 1130 Node* AllocateAndInitJSPromise(Node* context);
1131 void PromiseInit(Node* promise); 1131 Node* AllocateAndSetJSPromise(Node* context, Node* status, Node* result);
1132 1132 void JSPromiseInit(Node* promise);
1133 // Other promise fields may also be need to set/reset. This only
1134 // provides a helper for certain init patterns.
1135 void PromiseSet(Node* promise, Node* status, Node* result);
1136 1133
1137 Node* AllocatePromiseReactionJobInfo(Node* promise, Node* value, Node* tasks, 1134 Node* AllocatePromiseReactionJobInfo(Node* promise, Node* value, Node* tasks,
1138 Node* deferred_promise, 1135 Node* deferred_promise,
1139 Node* deferred_on_resolve, 1136 Node* deferred_on_resolve,
1140 Node* deferred_on_reject, Node* context); 1137 Node* deferred_on_reject, Node* context);
1141 1138
1142 protected: 1139 protected:
1143 void DescriptorLookupLinear(Node* unique_name, Node* descriptors, Node* nof, 1140 void DescriptorLookupLinear(Node* unique_name, Node* descriptors, Node* nof,
1144 Label* if_found, Variable* var_name_index, 1141 Label* if_found, Variable* var_name_index,
1145 Label* if_not_found); 1142 Label* if_not_found);
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
1243 } 1240 }
1244 #else 1241 #else
1245 #define CSA_SLOW_ASSERT(csa, x) ((void)0) 1242 #define CSA_SLOW_ASSERT(csa, x) ((void)0)
1246 #endif 1243 #endif
1247 1244
1248 DEFINE_OPERATORS_FOR_FLAGS(CodeStubAssembler::AllocationFlags); 1245 DEFINE_OPERATORS_FOR_FLAGS(CodeStubAssembler::AllocationFlags);
1249 1246
1250 } // namespace internal 1247 } // namespace internal
1251 } // namespace v8 1248 } // namespace v8
1252 #endif // V8_CODE_STUB_ASSEMBLER_H_ 1249 #endif // V8_CODE_STUB_ASSEMBLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698