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 // TCP cubic send side congestion algorithm, emulates the behavior of TCP cubic. | 5 // TCP cubic send side congestion algorithm, emulates the behavior of TCP cubic. |
6 | 6 |
7 #ifndef NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_BASE_H_ | 7 #ifndef NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_BASE_H_ |
8 #define NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_BASE_H_ | 8 #define NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_BASE_H_ |
9 | 9 |
10 #include <stdint.h> | 10 #include <stdint.h> |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
75 | 75 |
76 // Called when initializing the minimum congestion window. | 76 // Called when initializing the minimum congestion window. |
77 virtual void SetMinCongestionWindowInPackets( | 77 virtual void SetMinCongestionWindowInPackets( |
78 QuicPacketCount congestion_window) = 0; | 78 QuicPacketCount congestion_window) = 0; |
79 | 79 |
80 // Called when slow start is exited to set SSTHRESH. | 80 // Called when slow start is exited to set SSTHRESH. |
81 virtual void ExitSlowstart() = 0; | 81 virtual void ExitSlowstart() = 0; |
82 | 82 |
83 // Called when a packet is lost. | 83 // Called when a packet is lost. |
84 virtual void OnPacketLost(QuicPacketNumber largest_loss, | 84 virtual void OnPacketLost(QuicPacketNumber largest_loss, |
| 85 QuicByteCount lost_bytes, |
85 QuicByteCount bytes_in_flight) = 0; | 86 QuicByteCount bytes_in_flight) = 0; |
86 | 87 |
87 // Called when a packet has been acked to possibly increase the congestion | 88 // Called when a packet has been acked to possibly increase the congestion |
88 // window. | 89 // window. |
89 virtual void MaybeIncreaseCwnd(QuicPacketNumber acked_packet_number, | 90 virtual void MaybeIncreaseCwnd(QuicPacketNumber acked_packet_number, |
90 QuicByteCount acked_bytes, | 91 QuicByteCount acked_bytes, |
91 QuicByteCount bytes_in_flight) = 0; | 92 QuicByteCount bytes_in_flight) = 0; |
92 | 93 |
93 // Called when a retransmission has occured which resulted in packets | 94 // Called when a retransmission has occured which resulted in packets |
94 // being retransmitted. | 95 // being retransmitted. |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
139 // When true, exit slow start with large cutback of congestion window. | 140 // When true, exit slow start with large cutback of congestion window. |
140 bool slow_start_large_reduction_; | 141 bool slow_start_large_reduction_; |
141 | 142 |
142 private: | 143 private: |
143 DISALLOW_COPY_AND_ASSIGN(TcpCubicSenderBase); | 144 DISALLOW_COPY_AND_ASSIGN(TcpCubicSenderBase); |
144 }; | 145 }; |
145 | 146 |
146 } // namespace net | 147 } // namespace net |
147 | 148 |
148 #endif // NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_BASE_H_ | 149 #endif // NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_BASE_H_ |
OLD | NEW |