Index: src/full-codegen/arm64/full-codegen-arm64.cc |
diff --git a/src/full-codegen/arm64/full-codegen-arm64.cc b/src/full-codegen/arm64/full-codegen-arm64.cc |
index b7f87e12c44acacca830ad554a7101e9ee0ccb3e..7b716402cbe3f19ddd4950ce7f5a45d6f8168d69 100644 |
--- a/src/full-codegen/arm64/full-codegen-arm64.cc |
+++ b/src/full-codegen/arm64/full-codegen-arm64.cc |
@@ -1215,8 +1215,11 @@ |
// runtime function so that the new function we are creating here gets a |
// chance to have its code optimized and doesn't just get a copy of the |
// existing unoptimized code. |
- if (!FLAG_always_opt && !FLAG_prepare_always_opt && !pretenure && |
- scope()->is_function_scope()) { |
+ if (!FLAG_always_opt && |
+ !FLAG_prepare_always_opt && |
+ !pretenure && |
+ scope()->is_function_scope() && |
+ info->num_literals() == 0) { |
FastNewClosureStub stub(isolate(), info->language_mode(), info->kind()); |
__ Mov(x2, Operand(info)); |
__ CallStub(&stub); |