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

Unified Diff: src/ia32/codegen-ia32.cc

Issue 6677036: Fast path for strict closure creation. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 9 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/ia32/codegen-ia32.cc
diff --git a/src/ia32/codegen-ia32.cc b/src/ia32/codegen-ia32.cc
index f7c4808ba982e697b2b743d03e245f574b3dd422..3122d0ddb362ca51d665ce38c9508c60236202d1 100644
--- a/src/ia32/codegen-ia32.cc
+++ b/src/ia32/codegen-ia32.cc
@@ -4918,9 +4918,9 @@ Result CodeGenerator::InstantiateFunction(
// space for nested functions that don't need literals cloning.
if (!pretenure &&
scope()->is_function_scope() &&
- function_info->num_literals() == 0 &&
- !function_info->strict_mode()) { // Strict mode functions use slow path.
- FastNewClosureStub stub;
+ function_info->num_literals() == 0) {
+ FastNewClosureStub stub(
+ function_info->strict_mode() ? kStrictMode : kNonStrictMode);
frame()->EmitPush(Immediate(function_info));
return frame()->CallStub(&stub, 1);
} else {

Powered by Google App Engine
This is Rietveld 408576698