Index: chrome/browser/win/jumplist.cc |
diff --git a/chrome/browser/win/jumplist.cc b/chrome/browser/win/jumplist.cc |
index a9e27e77aa8de0baf1e25e1aa45957d14cd94f49..8af48d52caa956e1e91d96553275dac62291eee5 100644 |
--- a/chrome/browser/win/jumplist.cc |
+++ b/chrome/browser/win/jumplist.cc |
@@ -580,6 +580,8 @@ void JumpList::AddWindow(const sessions::TabRestoreService::Window& window, |
void JumpList::StartLoadingFavicon() { |
DCHECK(CalledOnValidThread()); |
+ base::ElapsedTimer timer; |
+ |
GURL url; |
bool waiting_for_icons = true; |
{ |
@@ -607,12 +609,18 @@ void JumpList::StartLoadingFavicon() { |
url, |
base::Bind(&JumpList::OnFaviconDataAvailable, base::Unretained(this)), |
&cancelable_task_tracker_); |
+ |
+ // TODO(chengx): Remove the UMA histogram after fixing http://crbug.com/717236 |
+ UMA_HISTOGRAM_TIMES("WinJumplist.StartLoadingFaviconDuration", |
+ timer.Elapsed()); |
} |
void JumpList::OnFaviconDataAvailable( |
const favicon_base::FaviconImageResult& image_result) { |
DCHECK(CalledOnValidThread()); |
+ base::ElapsedTimer timer; |
+ |
// If there is currently a favicon request in progress, it is now outdated, |
// as we have received another, so nullify the handle from the old request. |
task_id_ = base::CancelableTaskTracker::kBadTaskId; |
@@ -634,6 +642,11 @@ void JumpList::OnFaviconDataAvailable( |
if (!data->icon_urls_.empty()) |
data->icon_urls_.pop_front(); |
} |
+ |
+ // TODO(chengx): Remove the UMA histogram after fixing http://crbug.com/717236 |
+ UMA_HISTOGRAM_TIMES("WinJumplist.OnFaviconDataAvailableDuration", |
+ timer.Elapsed()); |
+ |
// Check whether we need to load more favicons. |
StartLoadingFavicon(); |
} |