| Index: src/runtime-profiler.cc
|
| diff --git a/src/runtime-profiler.cc b/src/runtime-profiler.cc
|
| index 20b0dc5753fb76f203298da6f56fa2906b179b4e..77d973ea134ffc0961f5cce599c4e3fbb7e31000 100644
|
| --- a/src/runtime-profiler.cc
|
| +++ b/src/runtime-profiler.cc
|
| @@ -402,8 +402,28 @@ OptimizationReason RuntimeProfiler::ShouldOptimizeIgnition(
|
| int typeinfo, generic, total, type_percentage, generic_percentage;
|
| GetICCounts(function, &typeinfo, &generic, &total, &type_percentage,
|
| &generic_percentage);
|
| - if (type_percentage >= FLAG_type_info_threshold) {
|
| - return OptimizationReason::kSmallFunction;
|
| + if (type_percentage < FLAG_type_info_threshold) {
|
| + if (FLAG_trace_opt_verbose) {
|
| + PrintF("[not yet optimizing ");
|
| + function->PrintName();
|
| + PrintF(
|
| + ", not enough type info for small function optimization: %d/%d "
|
| + "(%d%%)]\n",
|
| + typeinfo, total, type_percentage);
|
| + }
|
| + return OptimizationReason::kDoNotOptimize;
|
| + }
|
| + return OptimizationReason::kSmallFunction;
|
| + } else if (FLAG_trace_opt_verbose) {
|
| + PrintF("[not yet optimizing ");
|
| + function->PrintName();
|
| + PrintF(", not enough ticks: %d/%d and ", ticks,
|
| + kProfilerTicksBeforeOptimization);
|
| + if (any_ic_changed_) {
|
| + PrintF("ICs changed]\n");
|
| + } else {
|
| + PrintF(" too large for small function optimization: %d/%d]\n",
|
| + shared->bytecode_array()->Size(), kMaxSizeEarlyOptIgnition);
|
| }
|
| }
|
| return OptimizationReason::kDoNotOptimize;
|
|
|