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

Unified Diff: src/interpreter/interpreter.cc

Issue 2435023002: Use a different map to distinguish eval contexts (Closed)
Patch Set: relax dchecks Created 4 years, 1 month 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/interpreter/interpreter.cc
diff --git a/src/interpreter/interpreter.cc b/src/interpreter/interpreter.cc
index 81aecafecfdfbba9b465c7f54b6f1b685f6bf5e7..73c362138d507a910f1b475756ce5af6d4ca12c4 100644
--- a/src/interpreter/interpreter.cc
+++ b/src/interpreter/interpreter.cc
@@ -2264,6 +2264,18 @@ void Interpreter::DoCreateFunctionContext(InterpreterAssembler* assembler) {
__ Dispatch();
}
+// CreateEvalContext <slots>
+//
+// Creates a new context with number of |slots| for an eval closure.
+void Interpreter::DoCreateEvalContext(InterpreterAssembler* assembler) {
+ Node* closure = __ LoadRegister(Register::function_closure());
+ Node* slots = __ BytecodeOperandUImm(0);
+ Node* context = __ GetContext();
+ __ SetAccumulator(
+ FastNewEvalContextStub::Generate(assembler, closure, slots, context));
+ __ Dispatch();
+}
+
// CreateWithContext <register> <scope_info_idx>
//
// Creates a new context with the ScopeInfo at |scope_info_idx| for a

Powered by Google App Engine
This is Rietveld 408576698