Index: src/runtime/runtime-test.cc |
diff --git a/src/runtime/runtime-test.cc b/src/runtime/runtime-test.cc |
index 5117e42679b652045a299c43af26cce562793988..a52d858a6a186f5265717a7dac904e796247095c 100644 |
--- a/src/runtime/runtime-test.cc |
+++ b/src/runtime/runtime-test.cc |
@@ -135,6 +135,12 @@ RUNTIME_FUNCTION(Runtime_OptimizeOsr) { |
RUNTIME_ASSERT(function->shared()->allows_lazy_compilation() || |
!function->shared()->optimization_disabled()); |
+ // If funciton is interpreted, just return. OSR is not supported. |
rmcilroy
2016/04/12 12:56:56
/s/funciton/function.
mythria
2016/04/12 14:23:24
Thanks, Done.
|
+ // TODO(4764): Remove this check when OSR is enabled in the interpreter. |
+ if (function->shared()->HasBytecodeArray()) { |
+ return isolate->heap()->undefined_value(); |
+ } |
+ |
// If the function is already optimized, just return. |
if (function->IsOptimized()) return isolate->heap()->undefined_value(); |