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

Unified Diff: src/compiler.cc

Issue 2241783002: [interpreter] Compiler shortcut when bytecode present. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@local_cleanup-code-assembler
Patch Set: Rebased. Created 4 years, 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler.cc
diff --git a/src/compiler.cc b/src/compiler.cc
index 761c33755ea730ddf3c77233c5308149a196fa44..54ea359c6598631674cb232499c4defd9409ba21 100644
--- a/src/compiler.cc
+++ b/src/compiler.cc
@@ -1033,6 +1033,12 @@ MaybeHandle<Code> GetLazyCode(Handle<JSFunction> function) {
return Handle<Code>(function->shared()->code());
}
+ if (function->shared()->HasBytecodeArray()) {
+ Handle<Code> entry = isolate->builtins()->InterpreterEntryTrampoline();
+ function->shared()->ReplaceCode(*entry);
+ return entry;
+ }
+
Zone zone(isolate->allocator());
ParseInfo parse_info(&zone, function);
CompilationInfo info(&parse_info, function);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698