Index: src/compiler/pipeline.cc |
diff --git a/src/compiler/pipeline.cc b/src/compiler/pipeline.cc |
index 72f2093328facd81a8f93f2d098c781d341b4da6..1bd87b3befbf4c2e6b5711d21fdcf98a13d30720 100644 |
--- a/src/compiler/pipeline.cc |
+++ b/src/compiler/pipeline.cc |
@@ -151,6 +151,17 @@ static void TraceSchedule(Schedule* schedule) { |
Handle<Code> Pipeline::GenerateCode() { |
+ if (info()->function()->dont_optimize_reason() == kTryCatchStatement || |
+ info()->function()->dont_optimize_reason() == kTryFinallyStatement || |
+ // TODO(turbofan): Make ES6 for-of work and remove this bailout. |
+ info()->function()->dont_optimize_reason() == kForOfStatement || |
+ // TODO(turbofan): Make super work and remove this bailout. |
+ info()->function()->dont_optimize_reason() == kSuperReference || |
+ // TODO(turbofan): Make OSR work and remove this bailout. |
+ info()->is_osr()) { |
+ return Handle<Code>::null(); |
+ } |
+ |
if (FLAG_turbo_stats) isolate()->GetTStatistics()->Initialize(info_); |
if (FLAG_trace_turbo) { |