| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/flow_graph_inliner.h" | 5 #include "vm/flow_graph_inliner.h" |
| 6 | 6 |
| 7 #include "vm/aot_optimizer.h" | 7 #include "vm/aot_optimizer.h" |
| 8 #include "vm/block_scheduler.h" | 8 #include "vm/block_scheduler.h" |
| 9 #include "vm/branch_optimizer.h" | 9 #include "vm/branch_optimizer.h" |
| 10 #include "vm/compiler.h" | 10 #include "vm/compiler.h" |
| (...skipping 616 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 627 // Abort if the inlinable bit on the function is low. | 627 // Abort if the inlinable bit on the function is low. |
| 628 if (!function.CanBeInlined()) { | 628 if (!function.CanBeInlined()) { |
| 629 TRACE_INLINING(THR_Print(" Bailout: not inlinable\n")); | 629 TRACE_INLINING(THR_Print(" Bailout: not inlinable\n")); |
| 630 PRINT_INLINING_TREE("Not inlinable", | 630 PRINT_INLINING_TREE("Not inlinable", |
| 631 &call_data->caller, &function, call_data->call); | 631 &call_data->caller, &function, call_data->call); |
| 632 return false; | 632 return false; |
| 633 } | 633 } |
| 634 | 634 |
| 635 // Don't inline any intrinsified functions in precompiled mode | 635 // Don't inline any intrinsified functions in precompiled mode |
| 636 // to reduce code size and make sure we use the intrinsic code. | 636 // to reduce code size and make sure we use the intrinsic code. |
| 637 if (FLAG_precompiled_mode && function.is_intrinsic()) { | 637 if (FLAG_precompiled_mode && |
| 638 function.is_intrinsic() && |
| 639 !inliner_->AlwaysInline(function)) { |
| 638 TRACE_INLINING(THR_Print(" Bailout: intrinisic\n")); | 640 TRACE_INLINING(THR_Print(" Bailout: intrinisic\n")); |
| 639 PRINT_INLINING_TREE("intrinsic", | 641 PRINT_INLINING_TREE("intrinsic", |
| 640 &call_data->caller, &function, call_data->call); | 642 &call_data->caller, &function, call_data->call); |
| 641 return false; | 643 return false; |
| 642 } | 644 } |
| 643 | 645 |
| 644 // Do not rely on function type feedback or presence of code to determine | 646 // Do not rely on function type feedback or presence of code to determine |
| 645 // if a function was compiled. | 647 // if a function was compiled. |
| 646 if (!FLAG_precompiled_mode && !function.was_compiled()) { | 648 if (!FLAG_precompiled_mode && !function.was_compiled()) { |
| 647 TRACE_INLINING(THR_Print(" Bailout: not compiled yet\n")); | 649 TRACE_INLINING(THR_Print(" Bailout: not compiled yet\n")); |
| (...skipping 2579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3227 return InlineGrowableArraySetter( | 3229 return InlineGrowableArraySetter( |
| 3228 flow_graph, GrowableObjectArray::length_offset(), kNoStoreBarrier, | 3230 flow_graph, GrowableObjectArray::length_offset(), kNoStoreBarrier, |
| 3229 call, entry, last); | 3231 call, entry, last); |
| 3230 default: | 3232 default: |
| 3231 return false; | 3233 return false; |
| 3232 } | 3234 } |
| 3233 } | 3235 } |
| 3234 | 3236 |
| 3235 | 3237 |
| 3236 } // namespace dart | 3238 } // namespace dart |
| OLD | NEW |