Commit d3df2b05 authored by neis's avatar neis Committed by Commit bot

Make --turbo-stats output more self-explanatory.

BUG=

Review URL: https://codereview.chromium.org/1331553002

Cr-Commit-Position: refs/heads/master@{#30709}
parent 08dc4394
...@@ -67,16 +67,15 @@ static void WriteLine(std::ostream& os, const char* name, ...@@ -67,16 +67,15 @@ static void WriteLine(std::ostream& os, const char* name,
static_cast<double>(stats.total_allocated_bytes_ * 100) / static_cast<double>(stats.total_allocated_bytes_ * 100) /
static_cast<double>(total_stats.total_allocated_bytes_); static_cast<double>(total_stats.total_allocated_bytes_);
base::OS::SNPrintF(buffer, kBufferSize, base::OS::SNPrintF(buffer, kBufferSize,
"%28s %10.3f ms / %5.1f %%" "%28s %10.3f (%5.1f%%) "
"%10u total / %5.1f %% " "%10u (%5.1f%%) %10u %10u",
"%10u max %10u abs_max",
name, ms, percent, stats.total_allocated_bytes_, name, ms, percent, stats.total_allocated_bytes_,
size_percent, stats.max_allocated_bytes_, size_percent, stats.max_allocated_bytes_,
stats.absolute_max_allocated_bytes_); stats.absolute_max_allocated_bytes_);
os << buffer; os << buffer;
if (stats.function_name_.size() > 0) { if (stats.function_name_.size() > 0) {
os << " : " << stats.function_name_.c_str(); os << " " << stats.function_name_.c_str();
} }
os << std::endl; os << std::endl;
} }
...@@ -90,7 +89,10 @@ static void WriteFullLine(std::ostream& os) { ...@@ -90,7 +89,10 @@ static void WriteFullLine(std::ostream& os) {
static void WriteHeader(std::ostream& os) { static void WriteHeader(std::ostream& os) {
WriteFullLine(os); WriteFullLine(os);
os << " Turbofan timing results:\n"; os << " Turbonfan phase Time (ms) "
<< " Space (bytes) Function\n"
<< " "
<< " Total Max. Abs. max.\n";
WriteFullLine(os); WriteFullLine(os);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment