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

Side by Side Diff: chrome/renderer/render_view.cc

Issue 159759: Add renderer histograms for late binding of sockets. (Closed)
Patch Set: Make it compile Created 11 years, 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/renderer/render_view.h" 5 #include "chrome/renderer/render_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 2994 matching lines...) Expand 10 before | Expand all | Expand 10 after
3005 finish - start, kBeginToFinishMin, 3005 finish - start, kBeginToFinishMin,
3006 kBeginToFinishMax, kBeginToFinishBucketCount); 3006 kBeginToFinishMax, kBeginToFinishBucketCount);
3007 if (!request.is_null()) 3007 if (!request.is_null())
3008 UMA_HISTOGRAM_CUSTOM_TIMES( 3008 UMA_HISTOGRAM_CUSTOM_TIMES(
3009 FieldTrial::MakeName("Renderer4.RequestToFinish", 3009 FieldTrial::MakeName("Renderer4.RequestToFinish",
3010 "GlobalSdch").data(), 3010 "GlobalSdch").data(),
3011 finish - request, kBeginToFinishMin, 3011 finish - request, kBeginToFinishMin,
3012 kBeginToFinishMax, kBeginToFinishBucketCount); 3012 kBeginToFinishMax, kBeginToFinishBucketCount);
3013 } 3013 }
3014 3014
3015 static bool use_socket_late_binding_histogram =
3016 FieldTrialList::Find("SocketLateBinding") &&
3017 !FieldTrialList::Find("SocketLateBinding")->group_name().empty();
3018 if (use_socket_late_binding_histogram) {
3019 UMA_HISTOGRAM_CUSTOM_TIMES(
3020 FieldTrial::MakeName("Renderer4.BeginToFinish",
3021 "SocketLateBinding").data(),
3022 finish - begin, kBeginToFinishMin,
3023 kBeginToFinishMax, kBeginToFinishBucketCount);
3024 UMA_HISTOGRAM_CUSTOM_TIMES(
3025 FieldTrial::MakeName("Renderer4.StartToFinish",
3026 "SocketLateBinding").data(),
3027 finish - start, kBeginToFinishMin,
3028 kBeginToFinishMax, kBeginToFinishBucketCount);
3029 if (!request.is_null())
3030 UMA_HISTOGRAM_CUSTOM_TIMES(
3031 FieldTrial::MakeName("Renderer4.RequestToFinish",
3032 "SocketLateBinding").data(),
3033 finish - request, kBeginToFinishMin,
3034 kBeginToFinishMax, kBeginToFinishBucketCount);
3035 }
3036
3015 static bool use_cache_histogram1(FieldTrialList::Find("CacheSize") && 3037 static bool use_cache_histogram1(FieldTrialList::Find("CacheSize") &&
3016 !FieldTrialList::Find("CacheSize")->group_name().empty()); 3038 !FieldTrialList::Find("CacheSize")->group_name().empty());
3017 if (use_cache_histogram1) 3039 if (use_cache_histogram1)
3018 UMA_HISTOGRAM_CUSTOM_TIMES( 3040 UMA_HISTOGRAM_CUSTOM_TIMES(
3019 FieldTrial::MakeName("Renderer4.StartToFinish", "CacheSize").data(), 3041 FieldTrial::MakeName("Renderer4.StartToFinish", "CacheSize").data(),
3020 finish - start, kBeginToFinishMin, 3042 finish - start, kBeginToFinishMin,
3021 kBeginToFinishMax, kBeginToFinishBucketCount); 3043 kBeginToFinishMax, kBeginToFinishBucketCount);
3022 3044
3023 static bool use_cache_histogram2(FieldTrialList::Find("NewEviction") && 3045 static bool use_cache_histogram2(FieldTrialList::Find("NewEviction") &&
3024 !FieldTrialList::Find("NewEviction")->group_name().empty()); 3046 !FieldTrialList::Find("NewEviction")->group_name().empty());
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
3098 Send(new ViewHostMsg_PasswordFormsSeen(routing_id_, password_forms)); 3120 Send(new ViewHostMsg_PasswordFormsSeen(routing_id_, password_forms));
3099 } 3121 }
3100 3122
3101 void RenderView::Print(WebFrame* frame, bool script_initiated) { 3123 void RenderView::Print(WebFrame* frame, bool script_initiated) {
3102 DCHECK(frame); 3124 DCHECK(frame);
3103 if (print_helper_.get() == NULL) { 3125 if (print_helper_.get() == NULL) {
3104 print_helper_.reset(new PrintWebViewHelper(this)); 3126 print_helper_.reset(new PrintWebViewHelper(this));
3105 } 3127 }
3106 print_helper_->Print(frame, script_initiated); 3128 print_helper_->Print(frame, script_initiated);
3107 } 3129 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698