| 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 #include "src/runtime-profiler.h" | 5 #include "src/runtime-profiler.h" |
| 6 | 6 |
| 7 #include "src/assembler.h" | 7 #include "src/assembler.h" |
| 8 #include "src/base/platform/platform.h" | 8 #include "src/base/platform/platform.h" |
| 9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
| 10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
| (...skipping 386 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 397 for (int i = functions.length(); --i >= 0; ) { | 397 for (int i = functions.length(); --i >= 0; ) { |
| 398 SharedFunctionInfo* shared_function_info = functions[i]->shared(); | 398 SharedFunctionInfo* shared_function_info = functions[i]->shared(); |
| 399 int ticks = shared_function_info->profiler_ticks(); | 399 int ticks = shared_function_info->profiler_ticks(); |
| 400 if (ticks < Smi::kMaxValue) { | 400 if (ticks < Smi::kMaxValue) { |
| 401 shared_function_info->set_profiler_ticks(ticks + 1); | 401 shared_function_info->set_profiler_ticks(ticks + 1); |
| 402 } | 402 } |
| 403 } | 403 } |
| 404 | 404 |
| 405 Compiler::CompilationTier next_tier = | 405 Compiler::CompilationTier next_tier = |
| 406 Compiler::NextCompilationTier(function); | 406 Compiler::NextCompilationTier(function); |
| 407 if (function->shared()->HasBytecodeArray()) { | 407 if (function->shared()->code()->is_interpreter_trampoline_builtin()) { |
| 408 if (next_tier == Compiler::BASELINE) { | 408 if (next_tier == Compiler::BASELINE) { |
| 409 MaybeBaselineIgnition(function, frame); | 409 MaybeBaselineIgnition(function, frame); |
| 410 } else { | 410 } else { |
| 411 DCHECK_EQ(next_tier, Compiler::OPTIMIZED); | 411 DCHECK_EQ(next_tier, Compiler::OPTIMIZED); |
| 412 MaybeOptimizeIgnition(function, frame); | 412 MaybeOptimizeIgnition(function, frame); |
| 413 } | 413 } |
| 414 } else { | 414 } else { |
| 415 DCHECK_EQ(next_tier, Compiler::OPTIMIZED); | 415 DCHECK_EQ(next_tier, Compiler::OPTIMIZED); |
| 416 MaybeOptimizeFullCodegen(function, frame, frame_count); | 416 MaybeOptimizeFullCodegen(function, frame, frame_count); |
| 417 } | 417 } |
| 418 } | 418 } |
| 419 any_ic_changed_ = false; | 419 any_ic_changed_ = false; |
| 420 } | 420 } |
| 421 | 421 |
| 422 | 422 |
| 423 } // namespace internal | 423 } // namespace internal |
| 424 } // namespace v8 | 424 } // namespace v8 |
| OLD | NEW |