From 4b5dececfdff8d8d77e874224c02f1dab3a66369 Mon Sep 17 00:00:00 2001 From: Johannes Kron Date: Tue, 6 Dec 2022 15:02:28 +0000 Subject: [PATCH] Remove expired histograms WebRTC.BWE.Probing.* MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit These histograms have expired and have no owner. Remove to clean up the code and save memory. Fixed: chromium:1117100 Change-Id: I24a009d8e432109c1d62c4a3a16eff5cd21c8541 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/286660 Commit-Queue: Johannes Kron Reviewed-by: Erik Språng Cr-Commit-Position: refs/heads/main@{#38850} --- modules/pacing/bitrate_prober.cc | 19 ------------------- modules/pacing/bitrate_prober.h | 5 +---- 2 files changed, 1 insertion(+), 23 deletions(-) diff --git a/modules/pacing/bitrate_prober.cc b/modules/pacing/bitrate_prober.cc index ce45ea4e7a..e8ebf54f32 100644 --- a/modules/pacing/bitrate_prober.cc +++ b/modules/pacing/bitrate_prober.cc @@ -18,7 +18,6 @@ #include "logging/rtc_event_log/events/rtc_event_probe_cluster_created.h" #include "rtc_base/checks.h" #include "rtc_base/logging.h" -#include "system_wrappers/include/metrics.h" namespace webrtc { @@ -37,18 +36,9 @@ BitrateProberConfig::BitrateProberConfig( key_value_config->Lookup("WebRTC-Bwe-ProbingBehavior")); } -BitrateProber::~BitrateProber() { - RTC_HISTOGRAM_COUNTS_1000("WebRTC.BWE.Probing.TotalProbeClustersRequested", - total_probe_count_); - RTC_HISTOGRAM_COUNTS_1000("WebRTC.BWE.Probing.TotalFailedProbeClusters", - total_failed_probe_count_); -} - BitrateProber::BitrateProber(const FieldTrialsView& field_trials) : probing_state_(ProbingState::kDisabled), next_probe_time_(Timestamp::PlusInfinity()), - total_probe_count_(0), - total_failed_probe_count_(0), config_(&field_trials) { SetEnabled(true); } @@ -83,13 +73,11 @@ void BitrateProber::CreateProbeCluster( const ProbeClusterConfig& cluster_config) { RTC_DCHECK(probing_state_ != ProbingState::kDisabled); - total_probe_count_++; while (!clusters_.empty() && (cluster_config.at_time - clusters_.front().requested_at > kProbeClusterTimeout || clusters_.size() > kMaxPendingProbeClusters)) { clusters_.pop(); - total_failed_probe_count_++; } ProbeCluster cluster; @@ -171,13 +159,6 @@ void BitrateProber::ProbeSent(Timestamp now, DataSize size) { next_probe_time_ = CalculateNextProbeTime(*cluster); if (cluster->sent_bytes >= cluster->pace_info.probe_cluster_min_bytes && cluster->sent_probes >= cluster->pace_info.probe_cluster_min_probes) { - RTC_HISTOGRAM_COUNTS_100000("WebRTC.BWE.Probing.ProbeClusterSizeInBytes", - cluster->sent_bytes); - RTC_HISTOGRAM_COUNTS_100("WebRTC.BWE.Probing.ProbesPerCluster", - cluster->sent_probes); - RTC_HISTOGRAM_COUNTS_10000("WebRTC.BWE.Probing.TimePerProbeCluster", - (now - cluster->started_at).ms()); - clusters_.pop(); } if (clusters_.empty()) { diff --git a/modules/pacing/bitrate_prober.h b/modules/pacing/bitrate_prober.h index d2f1394262..4d8ec68c4f 100644 --- a/modules/pacing/bitrate_prober.h +++ b/modules/pacing/bitrate_prober.h @@ -45,7 +45,7 @@ struct BitrateProberConfig { class BitrateProber { public: explicit BitrateProber(const FieldTrialsView& field_trials); - ~BitrateProber(); + ~BitrateProber() = default; void SetEnabled(bool enable); @@ -118,9 +118,6 @@ class BitrateProber { // Time the next probe should be sent when in kActive state. Timestamp next_probe_time_; - int total_probe_count_; - int total_failed_probe_count_; - BitrateProberConfig config_; };