A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
tcp-bbr.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2018 NITK Surathkal
3 *
4 * SPDX-License-Identifier: GPL-2.0-only
5 *
6 * Authors: Vivek Jain <jain.vivek.anand@gmail.com>
7 * Viyom Mittal <viyommittal@gmail.com>
8 * Mohit P. Tahiliani <tahiliani@nitk.edu.in>
9 */
10
11#ifndef TCPBBR_H
12#define TCPBBR_H
13
14#include "tcp-congestion-ops.h"
15#include "windowed-filter.h"
16
17#include "ns3/data-rate.h"
18#include "ns3/random-variable-stream.h"
19#include "ns3/traced-value.h"
20
21class TcpBbrCheckGainValuesTest;
22
23namespace ns3
24{
25
26/**
27 * @ingroup congestionOps
28 *
29 * @brief BBR congestion control algorithm
30 *
31 * This class implement the BBR (Bottleneck Bandwidth and Round-trip propagation time)
32 * congestion control type.
33 */
35{
36 public:
37 /**
38 * @brief The number of phases in the BBR ProbeBW gain cycle.
39 */
40 static const uint8_t GAIN_CYCLE_LENGTH = 8;
41
42 /**
43 * @brief BBR uses an eight-phase cycle with the given pacing_gain value
44 * in the BBR ProbeBW gain cycle.
45 */
46 const static double PACING_GAIN_CYCLE[];
47 /**
48 * @brief Get the type ID.
49 * @return the object TypeId
50 */
51 static TypeId GetTypeId();
52
53 /**
54 * @brief Constructor
55 */
56 TcpBbr();
57
58 /**
59 * Copy constructor.
60 * @param sock The socket to copy from.
61 */
62 TcpBbr(const TcpBbr& sock);
63
64 /**
65 * @brief BBR has the following 4 modes for deciding how fast to send:
66 */
68 {
69 BBR_STARTUP, /**< Ramp up sending rate rapidly to fill pipe */
70 BBR_DRAIN, /**< Drain any queue created during startup */
71 BBR_PROBE_BW, /**< Discover, share bw: pace around estimated bw */
72 BBR_PROBE_RTT, /**< Cut inflight to min to probe min_rtt */
73 };
74
79 MaxBandwidthFilter_t; //!< Definition of max bandwidth filter.
80
81 /**
82 * @brief Literal names of BBR mode for use in log messages
83 */
84 static const char* const BbrModeName[BBR_PROBE_RTT + 1];
85
86 /**
87 * Assign a fixed random variable stream number to the random variables
88 * used by this model.
89 *
90 * @param stream first stream index to use
91 */
92 virtual void SetStream(uint32_t stream);
93
94 std::string GetName() const override;
95 bool HasCongControl() const override;
98 const TcpRateOps::TcpRateSample& rs) override;
100 const TcpSocketState::TcpCongState_t newState) override;
101 void CwndEvent(Ptr<TcpSocketState> tcb, const TcpSocketState::TcpCAEvent_t event) override;
102 uint32_t GetSsThresh(Ptr<const TcpSocketState> tcb, uint32_t bytesInFlight) override;
103 void SetRateOps(Ptr<TcpRateOps> rateOps) override;
104 Ptr<TcpCongestionOps> Fork() override;
105
106 public:
107 /**
108 * @brief TcpBbrCheckGainValuesTest friend class (for tests).
109 * @relates TcpBbrCheckGainValuesTest
110 */
111 friend class ::TcpBbrCheckGainValuesTest;
112
113 /**
114 * @brief Advances pacing gain using cycle gain algorithm, while in BBR_PROBE_BW state
115 */
116 void AdvanceCyclePhase();
117
118 /**
119 * @brief Checks whether to advance pacing gain in BBR_PROBE_BW state,
120 * and if allowed calls AdvanceCyclePhase ()
121 * @param tcb the socket state.
122 * @param rs rate sample.
123 */
125
126 /**
127 * @brief Checks whether its time to enter BBR_DRAIN or BBR_PROBE_BW state
128 * @param tcb the socket state.
129 */
131
132 /**
133 * @brief Identifies whether pipe or BDP is already full
134 * @param rs rate sample.
135 */
137
138 /**
139 * @brief This method handles the steps related to the ProbeRTT state
140 * @param tcb the socket state.
141 * @param rs rate sample.
142 */
144
145 /**
146 * @brief Updates variables specific to BBR_DRAIN state
147 */
148 void EnterDrain();
149
150 /**
151 * @brief Updates variables specific to BBR_PROBE_BW state
152 */
153 void EnterProbeBW();
154
155 /**
156 * @brief Updates variables specific to BBR_PROBE_RTT state
157 */
158 void EnterProbeRTT();
159
160 /**
161 * @brief Updates variables specific to BBR_STARTUP state
162 */
163 void EnterStartup();
164
165 /**
166 * @brief Called on exiting from BBR_PROBE_RTT state, it eithers invoke EnterProbeBW () or
167 * EnterStartup ()
168 */
169 void ExitProbeRTT();
170
171 /**
172 * @brief Gets BBR state.
173 * @return returns BBR state.
174 */
176
177 /**
178 * @brief Gets current pacing gain.
179 * @return returns current pacing gain.
180 */
181 double GetPacingGain();
182
183 /**
184 * @brief Gets current cwnd gain.
185 * @return returns current cwnd gain.
186 */
187 double GetCwndGain();
188
189 /**
190 * @brief Handles the steps for BBR_PROBE_RTT state.
191 * @param tcb the socket state.
192 */
194
195 /**
196 * @brief Updates pacing rate if socket is restarting from idle state.
197 * @param tcb the socket state.
198 * @param rs rate sample.
199 */
201
202 /**
203 * @brief Estimates the target value for congestion window
204 * @param tcb the socket state.
205 * @param gain cwnd gain.
206 * @return returns congestion window based on max bandwidth and min RTT.
207 */
208 uint32_t InFlight(Ptr<TcpSocketState> tcb, double gain);
209
210 /**
211 * @brief Initializes the full pipe estimator.
212 */
213 void InitFullPipe();
214
215 /**
216 * @brief Initializes the pacing rate.
217 * @param tcb the socket state.
218 */
220
221 /**
222 * @brief Initializes the round counting related variables.
223 */
224 void InitRoundCounting();
225
226 /**
227 * @brief Checks whether to move to next value of pacing gain while in BBR_PROBE_BW.
228 * @param tcb the socket state.
229 * @param rs rate sample.
230 * @returns true if want to move to next value otherwise false.
231 */
233
234 /**
235 * @brief Modulates congestion window in BBR_PROBE_RTT.
236 * @param tcb the socket state.
237 */
239
240 /**
241 * @brief Modulates congestion window in CA_RECOVERY.
242 * @param tcb the socket state.
243 * @param rs rate sample.
244 * @return true if congestion window is updated in CA_RECOVERY.
245 */
247
248 /**
249 * @brief Helper to restore the last-known good congestion window
250 * @param tcb the socket state.
251 */
253
254 /**
255 * @brief Helper to remember the last-known good congestion window or
256 * the latest congestion window unmodulated by loss recovery or ProbeRTT.
257 * @param tcb the socket state.
258 */
260
261 /**
262 * @brief Updates congestion window based on the network model.
263 * @param tcb the socket state.
264 * @param rs rate sample
265 */
267
268 /**
269 * @brief Updates pacing rate based on network model.
270 * @param tcb the socket state.
271 * @param gain pacing gain.
272 */
273 void SetPacingRate(Ptr<TcpSocketState> tcb, double gain);
274
275 /**
276 * @brief Updates send quantum based on the network model.
277 * @param tcb the socket state.
278 */
280
281 /**
282 * @brief Updates maximum bottleneck.
283 * @param tcb the socket state.
284 * @param rs rate sample.
285 */
287
288 /**
289 * @brief Updates control parameters congestion windowm, pacing rate, send quantum.
290 * @param tcb the socket state.
291 * @param rs rate sample.
292 */
294
295 /**
296 * @brief Updates BBR network model (Maximum bandwidth and minimum RTT).
297 * @param tcb the socket state.
298 * @param rs rate sample.
299 */
301
302 /**
303 * @brief Updates round counting related variables.
304 * @param tcb the socket state.
305 * @param rs rate sample.
306 */
308
309 /**
310 * @brief Updates minimum RTT.
311 * @param tcb the socket state.
312 */
314
315 /**
316 * @brief Updates target congestion window.
317 * @param tcb the socket state.
318 */
320
321 /**
322 * @brief Sets BBR state.
323 * @param state BBR state.
324 */
325 void SetBbrState(BbrMode_t state);
326
327 /**
328 * @brief Find Cwnd increment based on ack aggregation.
329 * @return uint32_t aggregate cwnd.
330 */
332
333 /**
334 * @brief Estimates max degree of aggregation.
335 * @param tcb the socket state.
336 * @param rs rate sample.
337 */
339
340 private:
341 BbrMode_t m_state{BbrMode_t::BBR_STARTUP}; //!< Current state of BBR state machine
342 MaxBandwidthFilter_t m_maxBwFilter; //!< Maximum bandwidth filter
343 uint32_t m_bandwidthWindowLength{0}; //!< A constant specifying the length of the BBR.BtlBw max
344 //!< filter window, default 10 packet-timed round trips.
345 TracedValue<double> m_pacingGain{0}; //!< The dynamic pacing gain factor
346 TracedValue<double> m_cWndGain{0}; //!< The dynamic congestion window gain factor
347 double m_highGain{0}; //!< A constant specifying highest gain factor, default is 2.89
348 bool m_isPipeFilled{false}; //!< A boolean that records whether BBR has filled the pipe
350 0}; //!< The minimal congestion window value BBR tries to target, default 4 Segment size
351 uint32_t m_roundCount{0}; //!< Count of packet-timed round trips
352 bool m_roundStart{false}; //!< A boolean that BBR sets to true once per packet-timed round trip
353 uint32_t m_nextRoundDelivered{0}; //!< Denotes the end of a packet-timed round trip
354 Time m_probeRttDuration{MilliSeconds(200)}; //!< A constant specifying the minimum duration for
355 //!< which ProbeRTT state, default 200 millisecs
356 Time m_probeRtPropStamp; //!< The wall clock time at which the current BBR.RTProp sample was
357 //!< obtained.
358 Time m_probeRttDoneStamp; //!< Time to exit from BBR_PROBE_RTT state
359 bool m_probeRttRoundDone{false}; //!< True when it is time to exit BBR_PROBE_RTT
360 bool m_packetConservation{false}; //!< Enable/Disable packet conservation mode
361 uint32_t m_priorCwnd{0}; //!< The last-known good congestion window
362 bool m_idleRestart{false}; //!< When restarting from idle, set it true
363 uint32_t m_targetCWnd{0}; //!< Target value for congestion window, adapted to the estimated BDP
364 DataRate m_fullBandwidth{0}; //!< Value of full bandwidth recorded
365 uint32_t m_fullBandwidthCount{0}; //!< Count of full bandwidth recorded consistently
367 Time::Max()}; //!< Estimated two-way round-trip propagation delay of the path, estimated
368 //!< from the windowed minimum recent round-trip delay sample.
370 0}; //!< The maximum size of a data aggregate scheduled and transmitted together
371 Time m_cycleStamp; //!< Last time gain cycle updated
372 uint32_t m_cycleIndex{0}; //!< Current index of gain cycle
373 bool m_minRttExpired{false}; //!< A boolean recording whether the BBR.RTprop has expired
374 Time m_minRttFilterLen{Seconds(10)}; //!< A constant specifying the length of the RTProp min
375 //!< filter window, default 10 secs.
376 Time m_minRttStamp; //!< The wall clock time at which the current BBR.RTProp sample was obtained
377 bool m_isInitialized{false}; //!< Set to true after first time initialization variables
378 Ptr<UniformRandomVariable> m_uv{nullptr}; //!< Uniform Random Variable
379 uint64_t m_delivered{0}; //!< The total amount of data in bytes delivered so far
380 Ptr<TcpRateOps> m_rateOps; //!< Rate operations
381 uint32_t m_extraAckedGain{1}; //!< Gain factor for adding extra ack to cwnd
382 uint32_t m_extraAcked[2]{0, 0}; //!< Maximum excess data acked in epoch
383 uint32_t m_extraAckedWinRtt{0}; //!< Age of extra acked in rtt
384 uint32_t m_extraAckedWinRttLength{5}; //!< Window length of extra acked window
386 1 << 17}; //!< Max allowed val for m_ackEpochAcked, after which sampling epoch is reset
387 uint32_t m_extraAckedIdx{0}; //!< Current index in extra acked array
388 Time m_ackEpochTime; //!< Starting of ACK sampling epoch time
389 uint32_t m_ackEpochAcked{0}; //!< Bytes ACked in sampling epoch
390 bool m_hasSeenRtt{false}; //!< Have we seen RTT sample yet?
391 double m_pacingMargin{0.01}; //!< BBR intentionally reduces the pacing rate by 1% to drain any
392 //!< standing queues. See `bbr_rate_bytes_per_sec` in Linux.
393};
394
395} // namespace ns3
396#endif // TCPBBR_H
Class for representing data rates.
Definition data-rate.h:78
Smart pointer class similar to boost::intrusive_ptr.
BBR congestion control algorithm.
Definition tcp-bbr.h:35
MaxBandwidthFilter_t m_maxBwFilter
Maximum bandwidth filter.
Definition tcp-bbr.h:342
bool m_hasSeenRtt
Have we seen RTT sample yet?
Definition tcp-bbr.h:390
Time m_minRttFilterLen
A constant specifying the length of the RTProp min filter window, default 10 secs.
Definition tcp-bbr.h:374
void ModulateCwndForProbeRTT(Ptr< TcpSocketState > tcb)
Modulates congestion window in BBR_PROBE_RTT.
Definition tcp-bbr.cc:562
uint32_t m_nextRoundDelivered
Denotes the end of a packet-timed round trip.
Definition tcp-bbr.h:353
BbrMode_t
BBR has the following 4 modes for deciding how fast to send:
Definition tcp-bbr.h:68
@ BBR_PROBE_RTT
Cut inflight to min to probe min_rtt.
Definition tcp-bbr.h:72
@ BBR_DRAIN
Drain any queue created during startup.
Definition tcp-bbr.h:70
@ BBR_STARTUP
Ramp up sending rate rapidly to fill pipe.
Definition tcp-bbr.h:69
@ BBR_PROBE_BW
Discover, share bw: pace around estimated bw.
Definition tcp-bbr.h:71
uint32_t m_roundCount
Count of packet-timed round trips.
Definition tcp-bbr.h:351
uint32_t m_priorCwnd
The last-known good congestion window.
Definition tcp-bbr.h:361
uint32_t m_extraAckedWinRttLength
Window length of extra acked window.
Definition tcp-bbr.h:384
bool m_minRttExpired
A boolean recording whether the BBR.RTprop has expired.
Definition tcp-bbr.h:373
void SetRateOps(Ptr< TcpRateOps > rateOps) override
Set rate operation required by the congestion control algorithm.
Definition tcp-bbr.cc:135
virtual void SetStream(uint32_t stream)
Assign a fixed random variable stream number to the random variables used by this model.
Definition tcp-bbr.cc:148
TcpBbr()
Constructor.
Definition tcp-bbr.cc:84
uint32_t m_extraAckedIdx
Current index in extra acked array.
Definition tcp-bbr.h:387
Time m_probeRtPropStamp
The wall clock time at which the current BBR.RTProp sample was obtained.
Definition tcp-bbr.h:356
std::string GetName() const override
Get the name of the congestion control algorithm.
Definition tcp-bbr.cc:694
void CongControl(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateConnection &rc, const TcpRateOps::TcpRateSample &rs) override
Called when packets are delivered to update cwnd and pacing rate.
Definition tcp-bbr.cc:707
void CwndEvent(Ptr< TcpSocketState > tcb, const TcpSocketState::TcpCAEvent_t event) override
Trigger events/calculations on occurrence of congestion window event.
Definition tcp-bbr.cc:761
uint32_t GetSsThresh(Ptr< const TcpSocketState > tcb, uint32_t bytesInFlight) override
Get the slow start threshold after a loss event.
Definition tcp-bbr.cc:794
uint32_t m_bandwidthWindowLength
A constant specifying the length of the BBR.BtlBw max filter window, default 10 packet-timed round tr...
Definition tcp-bbr.h:343
double m_highGain
A constant specifying highest gain factor, default is 2.89.
Definition tcp-bbr.h:347
Time m_probeRttDuration
A constant specifying the minimum duration for which ProbeRTT state, default 200 millisecs.
Definition tcp-bbr.h:354
void CheckCyclePhase(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Checks whether to advance pacing gain in BBR_PROBE_BW state, and if allowed calls AdvanceCyclePhase (...
Definition tcp-bbr.cc:292
uint32_t AckAggregationCwnd()
Find Cwnd increment based on ack aggregation.
Definition tcp-bbr.cc:483
bool m_idleRestart
When restarting from idle, set it true.
Definition tcp-bbr.h:362
Ptr< UniformRandomVariable > m_uv
Uniform Random Variable.
Definition tcp-bbr.h:378
static TypeId GetTypeId()
Get the type ID.
Definition tcp-bbr.cc:25
uint32_t m_minPipeCwnd
The minimal congestion window value BBR tries to target, default 4 Segment size.
Definition tcp-bbr.h:349
Ptr< TcpCongestionOps > Fork() override
Copy the congestion control algorithm across sockets.
Definition tcp-bbr.cc:802
uint32_t GetBbrState()
Gets BBR state.
Definition tcp-bbr.cc:673
bool HasCongControl() const override
Returns true when Congestion Control Algorithm implements CongControl.
Definition tcp-bbr.cc:700
TracedValue< double > m_cWndGain
The dynamic congestion window gain factor.
Definition tcp-bbr.h:346
double GetCwndGain()
Gets current cwnd gain.
Definition tcp-bbr.cc:680
void UpdateRound(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Updates round counting related variables.
Definition tcp-bbr.cc:607
BbrMode_t m_state
Current state of BBR state machine.
Definition tcp-bbr.h:341
bool m_roundStart
A boolean that BBR sets to true once per packet-timed round trip.
Definition tcp-bbr.h:352
void AdvanceCyclePhase()
Advances pacing gain using cycle gain algorithm, while in BBR_PROBE_BW state.
Definition tcp-bbr.cc:263
double m_pacingMargin
BBR intentionally reduces the pacing rate by 1% to drain any standing queues.
Definition tcp-bbr.h:391
void EnterProbeBW()
Updates variables specific to BBR_PROBE_BW state.
Definition tcp-bbr.cc:336
double GetPacingGain()
Gets current pacing gain.
Definition tcp-bbr.cc:687
uint64_t m_delivered
The total amount of data in bytes delivered so far.
Definition tcp-bbr.h:379
Ptr< TcpRateOps > m_rateOps
Rate operations.
Definition tcp-bbr.h:380
void InitPacingRate(Ptr< TcpSocketState > tcb)
Initializes the pacing rate.
Definition tcp-bbr.cc:173
bool IsNextCyclePhase(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Checks whether to move to next value of pacing gain while in BBR_PROBE_BW.
Definition tcp-bbr.cc:272
bool m_isInitialized
Set to true after first time initialization variables.
Definition tcp-bbr.h:377
void RestoreCwnd(Ptr< TcpSocketState > tcb)
Helper to restore the last-known good congestion window.
Definition tcp-bbr.cc:398
bool ModulateCwndForRecovery(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Modulates congestion window in CA_RECOVERY.
Definition tcp-bbr.cc:544
static const char *const BbrModeName[BBR_PROBE_RTT+1]
Literal names of BBR mode for use in log messages.
Definition tcp-bbr.h:84
void UpdateRTprop(Ptr< TcpSocketState > tcb)
Updates minimum RTT.
Definition tcp-bbr.cc:363
void CheckDrain(Ptr< TcpSocketState > tcb)
Checks whether its time to enter BBR_DRAIN or BBR_PROBE_BW state.
Definition tcp-bbr.cc:347
void SetBbrState(BbrMode_t state)
Sets BBR state.
Definition tcp-bbr.cc:664
void UpdateBottleneckBandwidth(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Updates maximum bottleneck.
Definition tcp-bbr.cc:624
void HandleRestartFromIdle(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Updates pacing rate if socket is restarting from idle state.
Definition tcp-bbr.cc:211
static const double PACING_GAIN_CYCLE[]
BBR uses an eight-phase cycle with the given pacing_gain value in the BBR ProbeBW gain cycle.
Definition tcp-bbr.h:46
WindowedFilter< DataRate, MaxFilter< DataRate >, uint32_t, uint32_t > MaxBandwidthFilter_t
Definition of max bandwidth filter.
Definition tcp-bbr.h:79
bool m_isPipeFilled
A boolean that records whether BBR has filled the pipe.
Definition tcp-bbr.h:348
void EnterStartup()
Updates variables specific to BBR_STARTUP state.
Definition tcp-bbr.cc:202
void InitRoundCounting()
Initializes the round counting related variables.
Definition tcp-bbr.cc:155
void InitFullPipe()
Initializes the full pipe estimator.
Definition tcp-bbr.cc:164
void UpdateAckAggregation(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Estimates max degree of aggregation.
Definition tcp-bbr.cc:499
bool m_packetConservation
Enable/Disable packet conservation mode.
Definition tcp-bbr.h:360
uint32_t InFlight(Ptr< TcpSocketState > tcb, double gain)
Estimates the target value for congestion window.
Definition tcp-bbr.cc:245
uint32_t m_extraAckedWinRtt
Age of extra acked in rtt.
Definition tcp-bbr.h:383
void SetPacingRate(Ptr< TcpSocketState > tcb, double gain)
Updates pacing rate based on network model.
Definition tcp-bbr.cc:225
void SaveCwnd(Ptr< const TcpSocketState > tcb)
Helper to remember the last-known good congestion window or the latest congestion window unmodulated ...
Definition tcp-bbr.cc:384
void EnterDrain()
Updates variables specific to BBR_DRAIN state.
Definition tcp-bbr.cc:327
void CongestionStateSet(Ptr< TcpSocketState > tcb, const TcpSocketState::TcpCongState_t newState) override
Trigger events/calculations specific to a congestion state.
Definition tcp-bbr.cc:718
Time m_probeRttDoneStamp
Time to exit from BBR_PROBE_RTT state.
Definition tcp-bbr.h:358
uint32_t m_extraAcked[2]
Maximum excess data acked in epoch.
Definition tcp-bbr.h:382
void UpdateModelAndState(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Updates BBR network model (Maximum bandwidth and minimum RTT).
Definition tcp-bbr.cc:642
Time m_minRttStamp
The wall clock time at which the current BBR.RTProp sample was obtained.
Definition tcp-bbr.h:376
void UpdateControlParameters(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Updates control parameters congestion windowm, pacing rate, send quantum.
Definition tcp-bbr.cc:655
Time m_ackEpochTime
Starting of ACK sampling epoch time.
Definition tcp-bbr.h:388
Time m_cycleStamp
Last time gain cycle updated.
Definition tcp-bbr.h:371
void CheckFullPipe(const TcpRateOps::TcpRateSample &rs)
Identifies whether pipe or BDP is already full.
Definition tcp-bbr.cc:302
TracedValue< Time > m_minRtt
Estimated two-way round-trip propagation delay of the path, estimated from the windowed minimum recen...
Definition tcp-bbr.h:366
void EnterProbeRTT()
Updates variables specific to BBR_PROBE_RTT state.
Definition tcp-bbr.cc:375
DataRate m_fullBandwidth
Value of full bandwidth recorded.
Definition tcp-bbr.h:364
void HandleProbeRTT(Ptr< TcpSocketState > tcb)
Handles the steps for BBR_PROBE_RTT state.
Definition tcp-bbr.cc:419
uint32_t m_targetCWnd
Target value for congestion window, adapted to the estimated BDP.
Definition tcp-bbr.h:363
uint32_t m_sendQuantum
The maximum size of a data aggregate scheduled and transmitted together.
Definition tcp-bbr.h:369
void SetSendQuantum(Ptr< TcpSocketState > tcb)
Updates send quantum based on the network model.
Definition tcp-bbr.cc:469
uint32_t m_ackEpochAckedResetThresh
Max allowed val for m_ackEpochAcked, after which sampling epoch is reset.
Definition tcp-bbr.h:385
void ExitProbeRTT()
Called on exiting from BBR_PROBE_RTT state, it eithers invoke EnterProbeBW () or EnterStartup ()
Definition tcp-bbr.cc:405
bool m_probeRttRoundDone
True when it is time to exit BBR_PROBE_RTT.
Definition tcp-bbr.h:359
uint32_t m_fullBandwidthCount
Count of full bandwidth recorded consistently.
Definition tcp-bbr.h:365
void UpdateTargetCwnd(Ptr< TcpSocketState > tcb)
Updates target congestion window.
Definition tcp-bbr.cc:476
uint32_t m_cycleIndex
Current index of gain cycle.
Definition tcp-bbr.h:372
uint32_t m_extraAckedGain
Gain factor for adding extra ack to cwnd.
Definition tcp-bbr.h:381
void CheckProbeRTT(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
This method handles the steps related to the ProbeRTT state.
Definition tcp-bbr.cc:447
static const uint8_t GAIN_CYCLE_LENGTH
The number of phases in the BBR ProbeBW gain cycle.
Definition tcp-bbr.h:40
void SetCwnd(Ptr< TcpSocketState > tcb, const TcpRateOps::TcpRateSample &rs)
Updates congestion window based on the network model.
Definition tcp-bbr.cc:572
TracedValue< double > m_pacingGain
The dynamic pacing gain factor.
Definition tcp-bbr.h:345
uint32_t m_ackEpochAcked
Bytes ACked in sampling epoch.
Definition tcp-bbr.h:389
Congestion control abstract class.
TcpCAEvent_t
Congestion avoidance events.
TcpCongState_t
Definition of the Congestion state machine.
Simulation virtual time values and global simulation resolution.
Definition nstime.h:94
static Time Max()
Maximum representable Time Not to be confused with Max(Time,Time).
Definition nstime.h:286
Trace classes with value semantics.
a unique identifier for an interface.
Definition type-id.h:49
Construct a windowed filter.
Time Seconds(double value)
Construct a Time in the indicated unit.
Definition nstime.h:1345
Time MilliSeconds(uint64_t value)
Construct a Time in the indicated unit.
Definition nstime.h:1357
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Compares two values.
Information about the connection rate.
Rate Sample structure.