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

Unified Diff: src/compiler.cc

Issue 668143003: Move BailoutReason and flags computation to post-pass (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased on top of lgtm'd predecessor Created 6 years, 2 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 | « src/ast-numbering.cc ('k') | src/parser.cc » ('j') | 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 ad8325e9cff46119f69a69e4425e33608755debf..f445e43660c3ccd619b717f45e49fe9f85d294ea 100644
--- a/src/compiler.cc
+++ b/src/compiler.cc
@@ -741,7 +741,10 @@ static void InsertCodeIntoOptimizedCodeMap(CompilationInfo* info) {
static bool Renumber(CompilationInfo* info) {
if (!AstNumbering::Renumber(info->function(), info->zone())) return false;
if (!info->shared_info().is_null()) {
- info->shared_info()->set_ast_node_count(info->function()->ast_node_count());
+ FunctionLiteral* lit = info->function();
+ info->shared_info()->set_ast_node_count(lit->ast_node_count());
+ info->shared_info()->set_bailout_reason(lit->dont_optimize_reason());
+ info->shared_info()->set_dont_cache(lit->flags()->Contains(kDontCache));
}
return true;
}
@@ -928,6 +931,7 @@ bool Compiler::EnsureDeoptimizationSupport(CompilationInfo* info) {
unoptimized.PrepareForCompilation(info->scope());
unoptimized.SetContext(info->context());
unoptimized.EnableDeoptimizationSupport();
+ if (!Renumber(&unoptimized)) return false;
wingo 2014/10/24 09:51:50 whoops, this crept back in
wingo 2014/10/24 10:36:42 Done.
if (!FullCodeGenerator::MakeCode(&unoptimized)) return false;
Handle<SharedFunctionInfo> shared = info->shared_info();
« no previous file with comments | « src/ast-numbering.cc ('k') | src/parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698