Commit 56ca9a5a authored by Camillo Bruni's avatar Camillo Bruni Committed by Commit Bot

[printing] Print FeedbackVector similarly to other types


Change-Id: I3730443db3b6f67dd57e07f8d2f03a3b34a6b0a7
Reviewed-on: https://chromium-review.googlesource.com/796215
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: 's avatarPeter Marshall <petermarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49791}
parent 413129be
......@@ -748,29 +748,31 @@ void FeedbackVector::FeedbackVectorPrint(std::ostream& os) { // NOLINT
return;
}
os << "\n SharedFunctionInfo: " << Brief(shared_function_info());
os << "\n Optimized Code/Marker: ";
os << "\n - shared function info: " << Brief(shared_function_info());
os << "\n - optimized code/marker: ";
if (has_optimized_code()) {
os << Brief(optimized_code());
} else {
os << optimization_marker();
}
os << "\n Invocation Count: " << invocation_count();
os << "\n Profiler Ticks: " << profiler_ticks();
os << "\n - invocation count: " << invocation_count();
os << "\n - profiler ticks: " << profiler_ticks();
FeedbackMetadataIterator iter(metadata());
while (iter.HasNext()) {
FeedbackSlot slot = iter.Next();
FeedbackSlotKind kind = iter.kind();
os << "\n Slot " << slot << " " << kind << " ";
os << "\n - slot " << slot << " " << kind << " ";
FeedbackSlotPrint(os, slot, kind);
int entry_size = iter.entry_size();
if (entry_size > 0) os << " {";
for (int i = 0; i < entry_size; i++) {
int index = GetIndex(slot) + i;
os << "\n [" << index << "]: " << Brief(get(index));
os << "\n [" << index << "]: " << Brief(get(index));
}
if (entry_size > 0) os << "\n }";
}
os << "\n";
}
......
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