Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1928)

Unified Diff: runtime/vm/code_generator.cc

Issue 11031040: Don't inline functions above the deoptimization threshold. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Typo and added deopt increment Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/vm/deopt_instructions.cc » ('j') | runtime/vm/deopt_instructions.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/code_generator.cc
diff --git a/runtime/vm/code_generator.cc b/runtime/vm/code_generator.cc
index 2dffd5193e26e6a0f26ecab46b1dc1ae19f4a06e..a2325824e6af77b635422d4d07813cad77ac6cf1 100644
--- a/runtime/vm/code_generator.cc
+++ b/runtime/vm/code_generator.cc
@@ -1581,11 +1581,12 @@ DEFINE_LEAF_RUNTIME_ENTRY(intptr_t, DeoptimizeCopyFrame,
CopyFrame(optimized_code, *caller_frame);
if (FLAG_trace_deoptimization) {
- OS::Print("Deoptimizing (reason %d '%s') at pc %#"Px" '%s'\n",
+ OS::Print("Deoptimizing (reason %d '%s') at pc %#"Px" '%s' (count %d)\n",
deopt_reason,
DeoptReasonToText(deopt_reason),
caller_frame->pc(),
- Function::Handle(optimized_code.function()).ToFullyQualifiedCString());
+ Function::Handle(optimized_code.function()).ToFullyQualifiedCString(),
Kevin Millikin (Google) 2012/10/04 11:37:59 Not a bit deal, but we don't need two handles here
zerny-google 2012/10/04 12:18:41 Done.
+ Function::Handle(optimized_code.function()).deoptimization_counter());
}
// Compute the stack size of the unoptimized frame. For functions with
@@ -1679,14 +1680,6 @@ DEFINE_LEAF_RUNTIME_ENTRY(intptr_t, DeoptimizeFillFrame, uword last_fp) {
delete[] cpu_registers_copy;
delete[] xmm_registers_copy;
- // Clear invocation counter so that the function gets optimized after
- // classes have been collected.
- function.set_usage_counter(0);
- function.set_deoptimization_counter(function.deoptimization_counter() + 1);
-
- if (function.HasOptimizedCode()) {
- function.SwitchToUnoptimizedCode();
- }
return caller_fp;
}
END_LEAF_RUNTIME_ENTRY
« no previous file with comments | « no previous file | runtime/vm/deopt_instructions.cc » ('j') | runtime/vm/deopt_instructions.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698