| 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 9c01fa9c68ef9c4776d6e79a5c86a30a64a37436..ccc745932789401ae15f11d774a27ed4faacd68c 100644
|
| --- a/net/quic/congestion_control/tcp_cubic_sender.cc
|
| +++ b/net/quic/congestion_control/tcp_cubic_sender.cc
|
| @@ -36,6 +36,7 @@ TcpCubicSender::TcpCubicSender(
|
| rtt_stats_(rtt_stats),
|
| stats_(stats),
|
| reno_(reno),
|
| + num_connections_(2),
|
| congestion_window_count_(0),
|
| receive_window_(kDefaultSocketReceiveBuffer),
|
| prr_out_(0),
|
| @@ -77,6 +78,11 @@ void TcpCubicSender::SetFromConfig(const QuicConfig& config, bool is_server) {
|
| }
|
| }
|
|
|
| +void TcpCubicSender::SetNumEmulatedConnections(int num_connections) {
|
| + num_connections_ = num_connections;
|
| + cubic_.SetNumConnections(num_connections);
|
| +}
|
| +
|
| void TcpCubicSender::OnIncomingQuicCongestionFeedbackFrame(
|
| const QuicCongestionFeedbackFrame& feedback,
|
| QuicTime feedback_receive_time) {
|
| @@ -273,10 +279,11 @@ void TcpCubicSender::MaybeIncreaseCwnd(
|
| }
|
| // Congestion avoidance
|
| if (reno_) {
|
| - // Classic Reno congestion avoidance provided for testing.
|
| -
|
| + // Classic Reno congestion avoidance.
|
| ++congestion_window_count_;
|
| - if (congestion_window_count_ >= congestion_window_) {
|
| + // Divide by num_connections to smoothly increase the CWND at a faster
|
| + // rate than conventional Reno.
|
| + if (congestion_window_count_ * num_connections_ >= congestion_window_) {
|
| ++congestion_window_;
|
| congestion_window_count_ = 0;
|
| }
|
|
|