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

Unified Diff: src/compiler.cc

Issue 1153483002: [turbofan] Enable deoptimization for non-asm.js TurboFan code. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix Michis comment. REBASE Created 5 years, 7 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 | src/compiler/js-inlining.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 c3c14a5704d7ceef78c0c6ad5ab33bbe4af32357..717913613e52dbfbf1b8f5ec0eb636422e4ee486 100644
--- a/src/compiler.cc
+++ b/src/compiler.cc
@@ -114,7 +114,6 @@ CompilationInfo::CompilationInfo(ParseInfo* parse_info)
if (isolate_->debug()->is_active()) MarkAsDebug();
if (FLAG_context_specialization) MarkAsContextSpecializing();
- if (FLAG_turbo_deoptimization) MarkAsDeoptimizationEnabled();
if (FLAG_turbo_inlining) MarkAsInliningEnabled();
if (FLAG_turbo_source_positions) MarkAsSourcePositionsEnabled();
if (FLAG_turbo_splitting) MarkAsSplittingEnabled();
@@ -393,6 +392,10 @@ OptimizedCompileJob::Status OptimizedCompileJob::CreateGraph() {
info()->MarkAsTypeFeedbackEnabled();
info()->EnsureFeedbackVector();
}
+ if (!info()->shared_info()->asm_function() ||
+ FLAG_turbo_asm_deoptimization) {
+ info()->MarkAsDeoptimizationEnabled();
+ }
Timer t(this, &time_taken_to_create_graph_);
compiler::Pipeline pipeline(info());
@@ -502,7 +505,7 @@ OptimizedCompileJob::Status OptimizedCompileJob::GenerateCode() {
// TODO(turbofan): Currently everything is done in the first phase.
if (!info()->code().is_null()) {
info()->dependencies()->Commit(info()->code());
- if (FLAG_turbo_deoptimization) {
+ if (info()->is_deoptimization_enabled()) {
info()->parse_info()->context()->native_context()->AddOptimizedCode(
*info()->code());
}
@@ -848,7 +851,7 @@ MaybeHandle<Code> Compiler::GetLazyCode(Handle<JSFunction> function) {
// If the debugger is active, do not compile with turbofan unless we can
// deopt from turbofan code.
if (FLAG_turbo_asm && function->shared()->asm_function() &&
- (FLAG_turbo_deoptimization || !isolate->debug()->is_active()) &&
+ (FLAG_turbo_asm_deoptimization || !isolate->debug()->is_active()) &&
!FLAG_turbo_osr) {
CompilationInfoWithZone info(function);
« no previous file with comments | « no previous file | src/compiler/js-inlining.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698