From eec39190ce14bdb0e9b11e38904acbbd4efd8f1d Mon Sep 17 00:00:00 2001 From: Per Kjellander Date: Thu, 24 Oct 2019 09:44:12 +0200 Subject: [PATCH] Remove trial WebRTC-Bwe-ProbeRateFallback It was intended to be used for to fall back to probe rate if ack rate is missing. This partly reverts commit aa4f100225e86723e75497aaf2d510588dcb9851. Reason for revert: Code is unused 1 year after submitted. Original change's description: > Adds trial to fall back to probe rate if ack rate is missing. > > Bug: webrtc:9718 > Change-Id: I7b6e1d3c051e67b97f6de1ec95e84631af9c5b0d > Reviewed-on: https://webrtc-review.googlesource.com/c/113600 > Commit-Queue: Sebastian Jansson > Reviewed-by: Niels Moller > Cr-Commit-Position: refs/heads/master@{#25953} # Not skipping CQ checks because original CL landed > 1 day ago. Bug: webrtc:9718 Change-Id: I06804782c2e210d1c484426e915e4d8447572739 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/158084 Commit-Queue: Per Kjellander Reviewed-by: Sebastian Jansson Reviewed-by: Per Kjellander Cr-Commit-Position: refs/heads/master@{#29597} --- .../goog_cc/goog_cc_network_control.cc | 11 +++-------- .../goog_cc/goog_cc_network_control.h | 1 - .../goog_cc/goog_cc_network_control_unittest.cc | 1 - .../goog_cc/probe_bitrate_estimator.cc | 7 +------ .../goog_cc/probe_bitrate_estimator.h | 3 --- 5 files changed, 4 insertions(+), 19 deletions(-) diff --git a/modules/congestion_controller/goog_cc/goog_cc_network_control.cc b/modules/congestion_controller/goog_cc/goog_cc_network_control.cc index c731d71c26..6b94bf30dd 100644 --- a/modules/congestion_controller/goog_cc/goog_cc_network_control.cc +++ b/modules/congestion_controller/goog_cc/goog_cc_network_control.cc @@ -70,8 +70,6 @@ GoogCcNetworkController::GoogCcNetworkController(NetworkControllerConfig config, use_downlink_delay_for_congestion_window_( IsEnabled(key_value_config_, "WebRTC-Bwe-CongestionWindowDownlinkDelay")), - fall_back_to_probe_rate_( - IsEnabled(key_value_config_, "WebRTC-Bwe-ProbeRateFallback")), use_min_allocatable_as_lower_bound_( IsNotDisabled(key_value_config_, "WebRTC-Bwe-MinAllocAsLowerBound")), rate_control_settings_( @@ -481,6 +479,9 @@ NetworkControlUpdate GoogCcNetworkController::OnTransportPacketsFeedback( acknowledged_bitrate_estimator_->IncomingPacketFeedbackVector( report.SortedByReceiveTime()); auto acknowledged_bitrate = acknowledged_bitrate_estimator_->bitrate(); + bandwidth_estimation_->SetAcknowledgedRate(acknowledged_bitrate, + report.feedback_time); + bandwidth_estimation_->IncomingPacketFeedbackVector(report); for (const auto& feedback : report.SortedByReceiveTime()) { if (feedback.sent_packet.pacing_info.probe_cluster_id != PacedPacketInfo::kNotAProbe) { @@ -490,12 +491,6 @@ NetworkControlUpdate GoogCcNetworkController::OnTransportPacketsFeedback( absl::optional probe_bitrate = probe_bitrate_estimator_->FetchAndResetLastEstimatedBitrate(); - if (fall_back_to_probe_rate_ && !acknowledged_bitrate) - acknowledged_bitrate = probe_bitrate_estimator_->last_estimate(); - bandwidth_estimation_->SetAcknowledgedRate(acknowledged_bitrate, - report.feedback_time); - bandwidth_estimation_->IncomingPacketFeedbackVector(report); - if (network_estimator_) { network_estimator_->OnTransportPacketsFeedback(report); auto prev_estimate = estimate_; diff --git a/modules/congestion_controller/goog_cc/goog_cc_network_control.h b/modules/congestion_controller/goog_cc/goog_cc_network_control.h index 0c4fca0e0e..6710d89383 100644 --- a/modules/congestion_controller/goog_cc/goog_cc_network_control.h +++ b/modules/congestion_controller/goog_cc/goog_cc_network_control.h @@ -86,7 +86,6 @@ class GoogCcNetworkController : public NetworkControllerInterface { FieldTrialFlag safe_reset_on_route_change_; FieldTrialFlag safe_reset_acknowledged_rate_; const bool use_downlink_delay_for_congestion_window_; - const bool fall_back_to_probe_rate_; const bool use_min_allocatable_as_lower_bound_; const RateControlSettings rate_control_settings_; diff --git a/modules/congestion_controller/goog_cc/goog_cc_network_control_unittest.cc b/modules/congestion_controller/goog_cc/goog_cc_network_control_unittest.cc index 0f73c7b52b..d74daec7ef 100644 --- a/modules/congestion_controller/goog_cc/goog_cc_network_control_unittest.cc +++ b/modules/congestion_controller/goog_cc/goog_cc_network_control_unittest.cc @@ -698,7 +698,6 @@ TEST_F(GoogCcNetworkControllerTest, CutsHighRateInSafeResetTrial) { TEST_F(GoogCcNetworkControllerTest, DetectsHighRateInSafeResetTrial) { ScopedFieldTrials trial( "WebRTC-Bwe-SafeResetOnRouteChange/Enabled,ack/" - "WebRTC-Bwe-ProbeRateFallback/Enabled/" "WebRTC-SendSideBwe-WithOverhead/Enabled/"); const DataRate kInitialLinkCapacity = DataRate::kbps(200); const DataRate kNewLinkCapacity = DataRate::kbps(800); diff --git a/modules/congestion_controller/goog_cc/probe_bitrate_estimator.cc b/modules/congestion_controller/goog_cc/probe_bitrate_estimator.cc index 7a157803e4..0a636fcf0a 100644 --- a/modules/congestion_controller/goog_cc/probe_bitrate_estimator.cc +++ b/modules/congestion_controller/goog_cc/probe_bitrate_estimator.cc @@ -171,9 +171,8 @@ absl::optional ProbeBitrateEstimator::HandleProbeAndEstimateBitrate( event_log_->Log( std::make_unique(cluster_id, res.bps())); } - last_estimate_ = res; estimated_data_rate_ = res; - return res; + return *estimated_data_rate_; } absl::optional @@ -183,10 +182,6 @@ ProbeBitrateEstimator::FetchAndResetLastEstimatedBitrate() { return estimated_data_rate; } -absl::optional ProbeBitrateEstimator::last_estimate() const { - return last_estimate_; -} - void ProbeBitrateEstimator::EraseOldClusters(Timestamp timestamp) { for (auto it = clusters_.begin(); it != clusters_.end();) { if (it->second.last_receive + kMaxClusterHistory < timestamp) { diff --git a/modules/congestion_controller/goog_cc/probe_bitrate_estimator.h b/modules/congestion_controller/goog_cc/probe_bitrate_estimator.h index bf9cb22eea..9f2f438ad9 100644 --- a/modules/congestion_controller/goog_cc/probe_bitrate_estimator.h +++ b/modules/congestion_controller/goog_cc/probe_bitrate_estimator.h @@ -33,8 +33,6 @@ class ProbeBitrateEstimator { absl::optional FetchAndResetLastEstimatedBitrate(); - absl::optional last_estimate() const; - private: struct AggregatedCluster { int num_probes = 0; @@ -53,7 +51,6 @@ class ProbeBitrateEstimator { std::map clusters_; RtcEventLog* const event_log_; absl::optional estimated_data_rate_; - absl::optional last_estimate_; }; } // namespace webrtc