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

Unified Diff: runtime/vm/code_generator.cc

Issue 11886008: Fix printing of deoptimized function. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 11 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') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/code_generator.cc
===================================================================
--- runtime/vm/code_generator.cc (revision 16998)
+++ runtime/vm/code_generator.cc (working copy)
@@ -1299,26 +1299,6 @@
}
-static void PrintCaller(const char* msg) {
- DartFrameIterator iterator;
- StackFrame* top_frame = iterator.NextFrame();
- ASSERT(top_frame != NULL);
- const Function& top_function = Function::Handle(
- top_frame->LookupDartFunction());
- OS::PrintErr("Failed: '%s' %s @ %#"Px"\n",
- msg, top_function.ToFullyQualifiedCString(), top_frame->pc());
- StackFrame* caller_frame = iterator.NextFrame();
- if (caller_frame != NULL) {
- const Function& caller_function = Function::Handle(
- caller_frame->LookupDartFunction());
- const Code& code = Code::Handle(caller_frame->LookupDartCode());
- OS::PrintErr(" -> caller: %s (%s)\n",
- caller_function.ToFullyQualifiedCString(),
- code.is_optimized() ? "optimized" : "unoptimized");
- }
-}
-
-
DEFINE_RUNTIME_ENTRY(TraceICCall, 2) {
ASSERT(arguments.ArgCount() ==
kTraceICCallRuntimeEntry.argument_count());
@@ -1356,7 +1336,8 @@
if (function.deoptimization_counter() >=
FLAG_deoptimization_counter_threshold) {
if (FLAG_trace_failed_optimization_attempts) {
- PrintCaller("Too Many Deoptimizations");
+ OS::PrintErr("Too Many Deoptimizations: %s\n",
+ function.ToFullyQualifiedCString());
}
// TODO(srdjan): Investigate excessive deoptimization.
function.set_usage_counter(kLowInvocationCount);
« no previous file with comments | « no previous file | runtime/vm/deopt_instructions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698