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

Unified Diff: src/compiler/bytecode-graph-builder.cc

Issue 2187523002: [interpreter] Add CreateFunctionContext bytecode (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@fncontextstubslotparam
Patch Set: fix bytecode-generator Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: src/compiler/bytecode-graph-builder.cc
diff --git a/src/compiler/bytecode-graph-builder.cc b/src/compiler/bytecode-graph-builder.cc
index ab320d504ace83eda0c1b7d4d4d60b409c0929b6..9ce6457315b39cc093216e82b726764a538e26e6 100644
--- a/src/compiler/bytecode-graph-builder.cc
+++ b/src/compiler/bytecode-graph-builder.cc
@@ -905,6 +905,13 @@ void BytecodeGraphBuilder::VisitCreateClosure() {
environment()->BindAccumulator(closure);
}
+void BytecodeGraphBuilder::VisitCreateFunctionContext() {
+ int32_t slots = bytecode_iterator().GetImmediateOperand(0);
+ const Operator* op = javascript()->CreateFunctionContext(slots);
+ Node* context = NewNode(op, GetFunctionClosure());
+ environment()->BindAccumulator(context);
+}
+
void BytecodeGraphBuilder::BuildCreateArguments(CreateArgumentsType type) {
FrameStateBeforeAndAfter states(this);
const Operator* op = javascript()->CreateArguments(type);

Powered by Google App Engine
This is Rietveld 408576698