| Index: net/quic/congestion_control/tcp_cubic_sender.cc
|
| diff --git a/net/quic/congestion_control/tcp_cubic_sender.cc b/net/quic/congestion_control/tcp_cubic_sender.cc
|
| index 9c438d45251e535c454dc358035ba276a9a9f73a..03cf38baa7f09faed12994c204ca9c2a63e47205 100644
|
| --- a/net/quic/congestion_control/tcp_cubic_sender.cc
|
| +++ b/net/quic/congestion_control/tcp_cubic_sender.cc
|
| @@ -38,7 +38,6 @@ TcpCubicSender::TcpCubicSender(
|
| reno_(reno),
|
| num_connections_(2),
|
| congestion_window_count_(0),
|
| - receive_window_(kDefaultSocketReceiveBuffer),
|
| prr_out_(0),
|
| prr_delivered_(0),
|
| ack_count_since_loss_(0),
|
| @@ -72,10 +71,6 @@ void TcpCubicSender::SetFromConfig(const QuicConfig& config, bool is_server) {
|
| config.ReceivedInitialCongestionWindow());
|
| }
|
| }
|
| - if (config.HasReceivedSocketReceiveBuffer()) {
|
| - // Set the initial socket receive buffer size in bytes.
|
| - receive_window_ = config.ReceivedSocketReceiveBuffer();
|
| - }
|
| }
|
|
|
| void TcpCubicSender::SetNumEmulatedConnections(int num_connections) {
|
| @@ -83,14 +78,6 @@ void TcpCubicSender::SetNumEmulatedConnections(int num_connections) {
|
| cubic_.SetNumConnections(num_connections_);
|
| }
|
|
|
| -void TcpCubicSender::OnIncomingQuicCongestionFeedbackFrame(
|
| - const QuicCongestionFeedbackFrame& feedback,
|
| - QuicTime feedback_receive_time) {
|
| - if (feedback.type == kTCP) {
|
| - receive_window_ = feedback.tcp.receive_window;
|
| - }
|
| -}
|
| -
|
| void TcpCubicSender::OnCongestionEvent(
|
| bool rtt_updated,
|
| QuicByteCount bytes_in_flight,
|
| @@ -193,17 +180,12 @@ QuicTime::Delta TcpCubicSender::TimeUntilSend(
|
| if (InRecovery()) {
|
| return PrrTimeUntilSend(bytes_in_flight);
|
| }
|
| - if (SendWindow() > bytes_in_flight) {
|
| + if (GetCongestionWindow() > bytes_in_flight) {
|
| return QuicTime::Delta::Zero();
|
| }
|
| return QuicTime::Delta::Infinite();
|
| }
|
|
|
| -QuicByteCount TcpCubicSender::SendWindow() const {
|
| - // What's the current send window in bytes.
|
| - return min(receive_window_, GetCongestionWindow());
|
| -}
|
| -
|
| QuicBandwidth TcpCubicSender::PacingRate() const {
|
| // We pace at twice the rate of the underlying sender's bandwidth estimate
|
| // during slow start and 1.25x during congestion avoidance to ensure pacing
|
| @@ -352,7 +334,7 @@ QuicTime::Delta TcpCubicSender::PrrTimeUntilSend(
|
| if (prr_out_ == 0 || bytes_in_flight < kMaxSegmentSize) {
|
| return QuicTime::Delta::Zero();
|
| }
|
| - if (SendWindow() > bytes_in_flight) {
|
| + if (GetCongestionWindow() > bytes_in_flight) {
|
| // During PRR-SSRB, limit outgoing packets to 1 extra MSS per ack, instead
|
| // of sending the entire available window. This prevents burst retransmits
|
| // when more packets are lost than the CWND reduction.
|
|
|