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

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

Issue 11228007: Remove the ConnCountImpact FieldTrial code. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 2 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/page_load_histograms.h" 5 #include "chrome/renderer/page_load_histograms.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/metrics/field_trial.h" 9 #include "base/metrics/field_trial.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 441 matching lines...) Expand 10 before | Expand all | Expand 10 after
452 case DocumentState::LINK_LOAD_CACHE_STALE_OK: 452 case DocumentState::LINK_LOAD_CACHE_STALE_OK:
453 PLT_HISTOGRAM(base::FieldTrial::MakeName( 453 PLT_HISTOGRAM(base::FieldTrial::MakeName(
454 "PLT.BeginToFinish_LinkLoadStaleOk", "ConnnectBackupJobs"), 454 "PLT.BeginToFinish_LinkLoadStaleOk", "ConnnectBackupJobs"),
455 begin_to_finish_all_loads); 455 begin_to_finish_all_loads);
456 break; 456 break;
457 default: 457 default:
458 break; 458 break;
459 } 459 }
460 } 460 }
461 461
462 // Histograms to determine if the number of connections has an
463 // impact on PLT.
464 // TODO(jar): Consider removing the per-link-type versions. We
465 // really only need LINK_LOAD_NORMAL and NORMAL_LOAD.
466 static const bool use_connection_impact_histogram =
467 base::FieldTrialList::TrialExists("ConnCountImpact");
468 if (use_connection_impact_histogram) {
469 UMA_HISTOGRAM_ENUMERATION(
470 base::FieldTrial::MakeName("PLT.Abandoned", "ConnCountImpact"),
471 abandoned_page ? 1 : 0, 2);
472 switch (load_type) {
473 case DocumentState::NORMAL_LOAD:
474 PLT_HISTOGRAM(base::FieldTrial::MakeName(
475 "PLT.BeginToFinish_NormalLoad", "ConnCountImpact"),
476 begin_to_finish_all_loads);
477 break;
478 case DocumentState::LINK_LOAD_NORMAL:
479 PLT_HISTOGRAM(base::FieldTrial::MakeName(
480 "PLT.BeginToFinish_LinkLoadNormal", "ConnCountImpact"),
481 begin_to_finish_all_loads);
482 break;
483 case DocumentState::LINK_LOAD_RELOAD:
484 PLT_HISTOGRAM(base::FieldTrial::MakeName(
485 "PLT.BeginToFinish_LinkLoadReload", "ConnCountImpact"),
486 begin_to_finish_all_loads);
487 break;
488 case DocumentState::LINK_LOAD_CACHE_STALE_OK:
489 PLT_HISTOGRAM(base::FieldTrial::MakeName(
490 "PLT.BeginToFinish_LinkLoadStaleOk", "ConnCountImpact"),
491 begin_to_finish_all_loads);
492 break;
493 default:
494 break;
495 }
496 }
497
498 // Histograms to determine effect of idle socket timeout. 462 // Histograms to determine effect of idle socket timeout.
499 static const bool use_idle_socket_timeout_histogram = 463 static const bool use_idle_socket_timeout_histogram =
500 base::FieldTrialList::TrialExists("IdleSktToImpact"); 464 base::FieldTrialList::TrialExists("IdleSktToImpact");
501 if (use_idle_socket_timeout_histogram) { 465 if (use_idle_socket_timeout_histogram) {
502 UMA_HISTOGRAM_ENUMERATION( 466 UMA_HISTOGRAM_ENUMERATION(
503 base::FieldTrial::MakeName("PLT.Abandoned", "IdleSktToImpact"), 467 base::FieldTrial::MakeName("PLT.Abandoned", "IdleSktToImpact"),
504 abandoned_page ? 1 : 0, 2); 468 abandoned_page ? 1 : 0, 2);
505 switch (load_type) { 469 switch (load_type) {
506 case DocumentState::NORMAL_LOAD: 470 case DocumentState::NORMAL_LOAD:
507 PLT_HISTOGRAM(base::FieldTrial::MakeName( 471 PLT_HISTOGRAM(base::FieldTrial::MakeName(
(...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after
992 956
993 DCHECK(document_state); 957 DCHECK(document_state);
994 DCHECK(ds); 958 DCHECK(ds);
995 GURL url(ds->request().url()); 959 GURL url(ds->request().url());
996 Time start = document_state->start_load_time(); 960 Time start = document_state->start_load_time();
997 Time finish = document_state->finish_load_time(); 961 Time finish = document_state->finish_load_time();
998 // TODO(mbelshe): should we log more stats? 962 // TODO(mbelshe): should we log more stats?
999 VLOG(1) << "PLT: " << (finish - start).InMilliseconds() << "ms " 963 VLOG(1) << "PLT: " << (finish - start).InMilliseconds() << "ms "
1000 << url.spec(); 964 << url.spec();
1001 } 965 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698