OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/compilation-info.h" | 5 #include "src/compilation-info.h" |
6 | 6 |
7 #include "src/api.h" | 7 #include "src/api.h" |
8 #include "src/ast/ast.h" | 8 #include "src/ast/ast.h" |
9 #include "src/ast/scopes.h" | 9 #include "src/ast/scopes.h" |
10 #include "src/isolate.h" | 10 #include "src/isolate.h" |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 isolate_(isolate), | 68 isolate_(isolate), |
69 flags_(0), | 69 flags_(0), |
70 code_flags_(code_flags), | 70 code_flags_(code_flags), |
71 mode_(mode), | 71 mode_(mode), |
72 osr_ast_id_(BailoutId::None()), | 72 osr_ast_id_(BailoutId::None()), |
73 zone_(zone), | 73 zone_(zone), |
74 deferred_handles_(nullptr), | 74 deferred_handles_(nullptr), |
75 dependencies_(isolate, zone), | 75 dependencies_(isolate, zone), |
76 bailout_reason_(kNoReason), | 76 bailout_reason_(kNoReason), |
77 prologue_offset_(Code::kPrologueOffsetNotSet), | 77 prologue_offset_(Code::kPrologueOffsetNotSet), |
78 track_positions_(FLAG_hydrogen_track_positions || | |
79 isolate->is_profiling()), | |
80 parameter_count_(0), | 78 parameter_count_(0), |
81 optimization_id_(-1), | 79 optimization_id_(-1), |
82 osr_expr_stack_height_(-1), | 80 osr_expr_stack_height_(-1), |
83 debug_name_(debug_name) {} | 81 debug_name_(debug_name) {} |
84 | 82 |
85 CompilationInfo::~CompilationInfo() { | 83 CompilationInfo::~CompilationInfo() { |
86 if (GetFlag(kDisableFutureOptimization) && has_shared_info()) { | 84 if (GetFlag(kDisableFutureOptimization) && has_shared_info()) { |
87 shared_info()->DisableOptimization(bailout_reason()); | 85 shared_info()->DisableOptimization(bailout_reason()); |
88 } | 86 } |
89 dependencies()->Rollback(); | 87 dependencies()->Rollback(); |
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
207 inlined_functions_.push_back(InlinedFunctionHolder( | 205 inlined_functions_.push_back(InlinedFunctionHolder( |
208 inlined_function, handle(inlined_function->code()))); | 206 inlined_function, handle(inlined_function->code()))); |
209 } | 207 } |
210 | 208 |
211 Code::Kind CompilationInfo::output_code_kind() const { | 209 Code::Kind CompilationInfo::output_code_kind() const { |
212 return Code::ExtractKindFromFlags(code_flags_); | 210 return Code::ExtractKindFromFlags(code_flags_); |
213 } | 211 } |
214 | 212 |
215 } // namespace internal | 213 } // namespace internal |
216 } // namespace v8 | 214 } // namespace v8 |
OLD | NEW |