| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 #ifndef V8_COMPILER_H_ | 5 #ifndef V8_COMPILER_H_ |
| 6 #define V8_COMPILER_H_ | 6 #define V8_COMPILER_H_ |
| 7 | 7 |
| 8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
| 9 #include "src/ast/ast.h" | 9 #include "src/ast/ast.h" |
| 10 #include "src/bailout-reason.h" | 10 #include "src/bailout-reason.h" |
| (...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 312 void MarkAsBailoutOnUninitialized() { SetFlag(kBailoutOnUninitialized); } | 312 void MarkAsBailoutOnUninitialized() { SetFlag(kBailoutOnUninitialized); } |
| 313 | 313 |
| 314 bool is_bailout_on_uninitialized() const { | 314 bool is_bailout_on_uninitialized() const { |
| 315 return GetFlag(kBailoutOnUninitialized); | 315 return GetFlag(kBailoutOnUninitialized); |
| 316 } | 316 } |
| 317 | 317 |
| 318 bool GeneratePreagedPrologue() const { | 318 bool GeneratePreagedPrologue() const { |
| 319 // Generate a pre-aged prologue if we are optimizing for size, which | 319 // Generate a pre-aged prologue if we are optimizing for size, which |
| 320 // will make code flushing more aggressive. Only apply to Code::FUNCTION, | 320 // will make code flushing more aggressive. Only apply to Code::FUNCTION, |
| 321 // since StaticMarkingVisitor::IsFlushable only flushes proper functions. | 321 // since StaticMarkingVisitor::IsFlushable only flushes proper functions. |
| 322 return FLAG_optimize_for_size && FLAG_age_code && !will_serialize() && | 322 return FLAG_optimize_for_size && FLAG_age_code && !is_debug() && |
| 323 !is_debug() && output_code_kind() == Code::FUNCTION; | 323 output_code_kind() == Code::FUNCTION; |
| 324 } | 324 } |
| 325 | 325 |
| 326 void EnsureFeedbackVector(); | 326 void EnsureFeedbackVector(); |
| 327 Handle<TypeFeedbackVector> feedback_vector() const { | 327 Handle<TypeFeedbackVector> feedback_vector() const { |
| 328 return feedback_vector_; | 328 return feedback_vector_; |
| 329 } | 329 } |
| 330 void SetCode(Handle<Code> code) { code_ = code; } | 330 void SetCode(Handle<Code> code) { code_ = code; } |
| 331 | 331 |
| 332 void SetBytecodeArray(Handle<BytecodeArray> bytecode_array) { | 332 void SetBytecodeArray(Handle<BytecodeArray> bytecode_array) { |
| 333 bytecode_array_ = bytecode_array; | 333 bytecode_array_ = bytecode_array; |
| (...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 655 OptimizedCompileJob* job_; | 655 OptimizedCompileJob* job_; |
| 656 base::ElapsedTimer timer_; | 656 base::ElapsedTimer timer_; |
| 657 base::TimeDelta* location_; | 657 base::TimeDelta* location_; |
| 658 }; | 658 }; |
| 659 }; | 659 }; |
| 660 | 660 |
| 661 } // namespace internal | 661 } // namespace internal |
| 662 } // namespace v8 | 662 } // namespace v8 |
| 663 | 663 |
| 664 #endif // V8_COMPILER_H_ | 664 #endif // V8_COMPILER_H_ |
| OLD | NEW |