| OLD | NEW |
| 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 "net/quic/congestion_control/tcp_cubic_sender.h" | 5 #include "net/quic/congestion_control/tcp_cubic_sender.h" |
| 6 | 6 |
| 7 namespace net { | 7 namespace net { |
| 8 | 8 |
| 9 namespace { | 9 namespace { |
| 10 // Constants based on TCP defaults. | 10 // Constants based on TCP defaults. |
| (...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 220 } | 220 } |
| 221 // Hybrid start triggers when cwnd is larger than some threshold. | 221 // Hybrid start triggers when cwnd is larger than some threshold. |
| 222 if (congestion_window_ <= slowstart_threshold_ && | 222 if (congestion_window_ <= slowstart_threshold_ && |
| 223 congestion_window_ >= kHybridStartLowWindow) { | 223 congestion_window_ >= kHybridStartLowWindow) { |
| 224 if (!hybrid_slow_start_.started()) { | 224 if (!hybrid_slow_start_.started()) { |
| 225 // Time to start the hybrid slow start. | 225 // Time to start the hybrid slow start. |
| 226 hybrid_slow_start_.Reset(end_sequence_number_); | 226 hybrid_slow_start_.Reset(end_sequence_number_); |
| 227 } | 227 } |
| 228 hybrid_slow_start_.Update(rtt, delay_min_); | 228 hybrid_slow_start_.Update(rtt, delay_min_); |
| 229 if (hybrid_slow_start_.Exit()) { | 229 if (hybrid_slow_start_.Exit()) { |
| 230 DLOG(INFO) << "Set slowstart threshold:" << congestion_window_; | |
| 231 slowstart_threshold_ = congestion_window_; | 230 slowstart_threshold_ = congestion_window_; |
| 232 } | 231 } |
| 233 } | 232 } |
| 234 } | 233 } |
| 235 | 234 |
| 236 } // namespace net | 235 } // namespace net |
| OLD | NEW |