#include "ns3/applications-module.h"#include "ns3/core-module.h"#include "ns3/internet-apps-module.h"#include "ns3/internet-module.h"#include "ns3/network-module.h"#include "ns3/point-to-point-module.h"#include "ns3/traffic-control-module.h"#include <fstream>#include <iostream>#include <string>
Include dependency graph for tcp-validation.cc:Go to the source code of this file.
Functions | |
| void | ScheduleFirstDctcpTraceConnection (std::ofstream *ofStream) |
| Schedule trace connection. | |
| void | ScheduleFirstPacketSinkConnection () |
| Schedule trace connection. | |
| void | ScheduleFirstTcpCwndTraceConnection (std::ofstream *ofStream) |
| Schedule trace connection. | |
| void | ScheduleFirstTcpRttTraceConnection (std::ofstream *ofStream) |
| Schedule trace connection. | |
| void | ScheduleSecondDctcpTraceConnection (std::ofstream *ofStream) |
| Schedule trace connection. | |
| void | ScheduleSecondPacketSinkConnection () |
| Schedule trace connection. | |
| void | ScheduleSecondTcpCwndTraceConnection (std::ofstream *ofStream) |
| Schedule trace connection. | |
| void | ScheduleSecondTcpRttTraceConnection (std::ofstream *ofStream) |
| Schedule trace connection. | |
| void | TraceFirstCwnd (std::ofstream *ofStream, uint32_t oldCwnd, uint32_t newCwnd) |
| Trace first congestion window. | |
| void | TraceFirstDctcp (std::ofstream *ofStream, uint32_t bytesMarked, uint32_t bytesAcked, double alpha) |
| Trace first TcpDctcp. | |
| void | TraceFirstRtt (std::ofstream *ofStream, Time oldRtt, Time newRtt) |
| Trace first RTT. | |
| void | TraceFirstRx (Ptr< const Packet > packet, const Address &address) |
| Trace first Rx. | |
| void | TraceFirstThroughput (std::ofstream *ofStream, Time throughputInterval) |
| Trace the first throughput. | |
| void | TraceMarksFrequency (std::ofstream *ofStream, Time marksSamplingInterval) |
| Trace marks frequency. | |
| void | TracePingRtt (std::ofstream *ofStream, uint16_t, Time rtt) |
| Trace ping RTT. | |
| void | TraceQueueDrop (std::ofstream *ofStream, Ptr< const QueueDiscItem > item) |
| Trace queue drop. | |
| void | TraceQueueLength (std::ofstream *ofStream, DataRate queueLinkRate, uint32_t oldVal, uint32_t newVal) |
| Trace queue length. | |
| void | TraceQueueMark (std::ofstream *ofStream, Ptr< const QueueDiscItem > item, const char *reason) |
| Trace queue marks. | |
| void | TraceSecondCwnd (std::ofstream *ofStream, uint32_t oldCwnd, uint32_t newCwnd) |
| Trace second congestion window. | |
| void | TraceSecondDctcp (std::ofstream *ofStream, uint32_t bytesMarked, uint32_t bytesAcked, double alpha) |
| Trace second TcpDctcp. | |
| void | TraceSecondRtt (std::ofstream *ofStream, Time oldRtt, Time newRtt) |
| Trace second RTT. | |
| void | TraceSecondRx (Ptr< const Packet > packet, const Address &address) |
| Trace second Rx. | |
| void | TraceSecondThroughput (std::ofstream *ofStream, Time throughputInterval) |
| Trace the second throughput. | |
Variables | |
| uint32_t | g_dropsObserved = 0 |
| Number of dropped packets observed. | |
| uint32_t | g_firstBytesReceived = 0 |
| First received packet size. | |
| uint32_t | g_marksObserved = 0 |
| Number of marked packets observed. | |
| uint32_t | g_secondBytesReceived = 0 |
| Second received packet size. | |
| std::string | g_validate = "" |
| Empty string disables validation. | |
| bool | g_validationFailed = false |
| True if validation failed. | |
$ ./ns3 run "tcp-validation [Program Options]"
--firstTcpType --secondTcpType --queueType --baseRtt --ceThreshold --linkRate --stopTime --queueUseEcn --enablePcap --validate Definition in file tcp-validation.cc.
| void ScheduleFirstDctcpTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
| ofStream | Output filestream. |
Definition at line 551 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeBoundCallback(), and TraceFirstDctcp().
Here is the call graph for this function:| void ScheduleFirstPacketSinkConnection | ( | ) |
Schedule trace connection.
Definition at line 575 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeCallback(), and TraceFirstRx().
Here is the call graph for this function:| void ScheduleFirstTcpCwndTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
| ofStream | Output filestream. |
Definition at line 526 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeBoundCallback(), and TraceFirstCwnd().
Here is the call graph for this function:| void ScheduleFirstTcpRttTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
| ofStream | Output filestream. |
Definition at line 539 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeBoundCallback(), and TraceFirstRtt().
Here is the call graph for this function:| void ScheduleSecondDctcpTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
| ofStream | Output filestream. |
Definition at line 564 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContextFailSafe(), ns3::MakeBoundCallback(), and TraceSecondDctcp().
Here is the call graph for this function:| void ScheduleSecondPacketSinkConnection | ( | ) |
Schedule trace connection.
Definition at line 609 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContext(), ns3::MakeCallback(), and TraceSecondRx().
Here is the call graph for this function:| void ScheduleSecondTcpCwndTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
| ofStream | Output filestream. |
Definition at line 587 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContext(), ns3::MakeBoundCallback(), and TraceSecondCwnd().
Here is the call graph for this function:| void ScheduleSecondTcpRttTraceConnection | ( | std::ofstream * | ofStream | ) |
Schedule trace connection.
| ofStream | Output filestream. |
Definition at line 599 of file tcp-validation.cc.
References ns3::Config::ConnectWithoutContext(), ns3::MakeBoundCallback(), and TraceSecondRtt().
Here is the call graph for this function:Trace first congestion window.
| ofStream | Output filestream. |
| oldCwnd | Old value. |
| newCwnd | new value. |
Definition at line 180 of file tcp-validation.cc.
References g_validate, g_validationFailed, ns3::Time::GetSeconds(), ns3::Now(), ns3::Simulator::Now(), NS_LOG_WARN, and ns3::Time::S.
Referenced by ScheduleFirstTcpCwndTraceConnection().
Here is the call graph for this function:
Here is the caller graph for this function:| void TraceFirstDctcp | ( | std::ofstream * | ofStream, |
| uint32_t | bytesMarked, | ||
| uint32_t | bytesAcked, | ||
| double | alpha | ||
| ) |
Trace first TcpDctcp.
| ofStream | Output filestream. |
| bytesMarked | Bytes marked. |
| bytesAcked | Bytes ACKed. |
| alpha | Alpha. |
Definition at line 226 of file tcp-validation.cc.
References g_validate, g_validationFailed, ns3::Time::GetSeconds(), ns3::Now(), ns3::Simulator::Now(), NS_LOG_WARN, and ns3::Time::S.
Referenced by ScheduleFirstDctcpTraceConnection().
Here is the call graph for this function:
Here is the caller graph for this function:Trace first RTT.
| ofStream | Output filestream. |
| oldRtt | Old value. |
| newRtt | New value. |
Definition at line 278 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Referenced by ScheduleFirstTcpRttTraceConnection().
Here is the call graph for this function:
Here is the caller graph for this function:Trace first Rx.
| packet | The packet. |
| address | The sender address. |
Definition at line 362 of file tcp-validation.cc.
References g_firstBytesReceived.
Referenced by ScheduleFirstPacketSinkConnection().
Here is the caller graph for this function:| void TraceFirstThroughput | ( | std::ofstream * | ofStream, |
| Time | throughputInterval | ||
| ) |
Trace the first throughput.
| ofStream | Output filestream. |
| throughputInterval | The throughput interval. |
Definition at line 459 of file tcp-validation.cc.
References g_firstBytesReceived, g_validate, g_validationFailed, ns3::Time::GetSeconds(), ns3::Now(), ns3::Simulator::Now(), NS_LOG_WARN, ns3::Time::S, ns3::Simulator::Schedule(), and TraceFirstThroughput().
Referenced by TraceFirstThroughput().
Here is the call graph for this function:
Here is the caller graph for this function:| void TraceMarksFrequency | ( | std::ofstream * | ofStream, |
| Time | marksSamplingInterval | ||
| ) |
Trace marks frequency.
| ofStream | Output filestream. |
| marksSamplingInterval | The mark sampling interval. |
Definition at line 439 of file tcp-validation.cc.
References g_marksObserved, g_validate, ns3::Time::GetSeconds(), ns3::Simulator::Now(), ns3::Simulator::Schedule(), and TraceMarksFrequency().
Referenced by TraceMarksFrequency().
Here is the call graph for this function:
Here is the caller graph for this function:| void TracePingRtt | ( | std::ofstream * | ofStream, |
| uint16_t | , | ||
| Time | rtt | ||
| ) |
Trace ping RTT.
| ofStream | Output filestream. |
| rtt | RTT value. |
Definition at line 347 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Here is the call graph for this function:| void TraceQueueDrop | ( | std::ofstream * | ofStream, |
| Ptr< const QueueDiscItem > | item | ||
| ) |
Trace queue drop.
| ofStream | Output filestream. |
| item | The dropped QueueDiscItem. |
Definition at line 386 of file tcp-validation.cc.
References g_dropsObserved, g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Here is the call graph for this function:| void TraceQueueLength | ( | std::ofstream * | ofStream, |
| DataRate | queueLinkRate, | ||
| uint32_t | oldVal, | ||
| uint32_t | newVal | ||
| ) |
Trace queue length.
| ofStream | Output filestream. |
| queueLinkRate | Queue link rate. |
| oldVal | Old value. |
| newVal | New value. |
Definition at line 421 of file tcp-validation.cc.
References g_validate, ns3::DataRate::GetBitRate(), ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Here is the call graph for this function:| void TraceQueueMark | ( | std::ofstream * | ofStream, |
| Ptr< const QueueDiscItem > | item, | ||
| const char * | reason | ||
| ) |
Trace queue marks.
| ofStream | Output filestream. |
| item | The marked QueueDiscItem. |
| reason | The reason. |
Definition at line 403 of file tcp-validation.cc.
References g_marksObserved, g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Here is the call graph for this function:Trace second congestion window.
| ofStream | Output filestream. |
| oldCwnd | Old value. |
| newCwnd | new value. |
Definition at line 295 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Referenced by ScheduleSecondTcpCwndTraceConnection().
Here is the call graph for this function:
Here is the caller graph for this function:| void TraceSecondDctcp | ( | std::ofstream * | ofStream, |
| uint32_t | bytesMarked, | ||
| uint32_t | bytesAcked, | ||
| double | alpha | ||
| ) |
Trace second TcpDctcp.
| ofStream | Output filestream. |
| bytesMarked | Bytes marked. |
| bytesAcked | Bytes ACKed. |
| alpha | Alpha. |
Definition at line 332 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Referenced by ScheduleSecondDctcpTraceConnection().
Here is the call graph for this function:
Here is the caller graph for this function:Trace second RTT.
| ofStream | Output filestream. |
| oldRtt | Old value. |
| newRtt | New value. |
Definition at line 314 of file tcp-validation.cc.
References g_validate, ns3::Time::GetSeconds(), and ns3::Simulator::Now().
Referenced by ScheduleSecondTcpRttTraceConnection().
Here is the call graph for this function:
Here is the caller graph for this function:Trace second Rx.
| packet | The packet. |
| address | The sender address. |
Definition at line 374 of file tcp-validation.cc.
References g_secondBytesReceived.
Referenced by ScheduleSecondPacketSinkConnection().
Here is the caller graph for this function:| void TraceSecondThroughput | ( | std::ofstream * | ofStream, |
| Time | throughputInterval | ||
| ) |
Trace the second throughput.
| ofStream | Output filestream. |
| throughputInterval | The throughput interval. |
Definition at line 509 of file tcp-validation.cc.
References g_secondBytesReceived, g_validate, ns3::Time::GetSeconds(), ns3::Simulator::Now(), ns3::Simulator::Schedule(), and TraceSecondThroughput().
Referenced by TraceSecondThroughput().
Here is the call graph for this function:
Here is the caller graph for this function:| uint32_t g_dropsObserved = 0 |
Number of dropped packets observed.
Definition at line 168 of file tcp-validation.cc.
Referenced by TraceQueueDrop().
| uint32_t g_firstBytesReceived = 0 |
First received packet size.
Definition at line 165 of file tcp-validation.cc.
Referenced by TraceFirstRx(), and TraceFirstThroughput().
| uint32_t g_marksObserved = 0 |
Number of marked packets observed.
Definition at line 167 of file tcp-validation.cc.
Referenced by TraceMarksFrequency(), and TraceQueueMark().
| uint32_t g_secondBytesReceived = 0 |
Second received packet size.
Definition at line 166 of file tcp-validation.cc.
Referenced by TraceSecondRx(), and TraceSecondThroughput().
| std::string g_validate = "" |
Empty string disables validation.
Definition at line 169 of file tcp-validation.cc.
Referenced by TraceFirstCwnd(), TraceFirstDctcp(), TraceFirstRtt(), TraceFirstThroughput(), TraceMarksFrequency(), TracePingRtt(), TraceQueueDrop(), TraceQueueLength(), TraceQueueMark(), TraceSecondCwnd(), TraceSecondDctcp(), TraceSecondRtt(), and TraceSecondThroughput().
| bool g_validationFailed = false |
True if validation failed.
Definition at line 170 of file tcp-validation.cc.
Referenced by TraceFirstCwnd(), TraceFirstDctcp(), and TraceFirstThroughput().