Index: src/runtime.cc |
diff --git a/src/runtime.cc b/src/runtime.cc |
index c7ff3a392b27748ddf4ae9231f24ff76ea33fed0..8e5e3536028219e8edca9d33e97cc0b7020a42d5 100644 |
--- a/src/runtime.cc |
+++ b/src/runtime.cc |
@@ -7405,6 +7405,16 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_DeoptimizeFunction) { |
} |
+RUNTIME_FUNCTION(MaybeObject*, Runtime_OptimizeFunctionOnNextCall) { |
+ HandleScope scope(isolate); |
+ ASSERT(args.length() == 1); |
+ CONVERT_ARG_CHECKED(JSFunction, function, 0); |
+ if (!function->IsOptimizable()) return isolate->heap()->undefined_value(); |
+ function->MarkForLazyRecompilation(); |
+ return isolate->heap()->undefined_value(); |
+} |
+ |
+ |
RUNTIME_FUNCTION(MaybeObject*, Runtime_CompileForOnStackReplacement) { |
HandleScope scope(isolate); |
ASSERT(args.length() == 1); |