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

Unified Diff: src/compiler/js-generic-lowering.cc

Issue 2435023002: Use a different map to distinguish eval contexts (Closed)
Patch Set: Crankshaft backends and scope deserialization Created 4 years, 2 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/js-generic-lowering.cc
diff --git a/src/compiler/js-generic-lowering.cc b/src/compiler/js-generic-lowering.cc
index ac36cc7913a82db3976569aa182831692be718f0..79bec3dd2fd3d74ed536d86a6dc432e7deb5023c 100644
--- a/src/compiler/js-generic-lowering.cc
+++ b/src/compiler/js-generic-lowering.cc
@@ -449,7 +449,16 @@ void JSGenericLowering::LowerJSCreateFunctionContext(Node* node) {
int const slot_count = OpParameter<int>(node->op());
CallDescriptor::Flags flags = FrameStateFlagForCall(node);
- Callable callable = CodeFactory::FastNewFunctionContext(isolate());
+ Callable callable = CodeFactory::FastNewFunctionContext(isolate(), false);
+ node->InsertInput(zone(), 1, jsgraph()->Int32Constant(slot_count));
+ ReplaceWithStubCall(node, callable, flags);
+}
+
+void JSGenericLowering::LowerJSCreateEvalContext(Node* node) {
+ int const slot_count = OpParameter<int>(node->op());
+ CallDescriptor::Flags flags = FrameStateFlagForCall(node);
+
+ Callable callable = CodeFactory::FastNewFunctionContext(isolate(), true);
node->InsertInput(zone(), 1, jsgraph()->Int32Constant(slot_count));
ReplaceWithStubCall(node, callable, flags);
}
« no previous file with comments | « src/compiler/js-create-lowering.cc ('k') | src/compiler/js-operator.h » ('j') | src/contexts.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698