Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(277)

Unified Diff: net/quic/congestion_control/send_algorithm_simulator.h

Issue 761903003: Update from https://crrev.com/306655 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/quic/congestion_control/send_algorithm_simulator.h
diff --git a/net/quic/congestion_control/send_algorithm_simulator.h b/net/quic/congestion_control/send_algorithm_simulator.h
index 3e61d88546e62a1cca2c626ee5db552fb412f924..7f52d8ffa3f3e479447c84ea70641e0269ae4517 100644
--- a/net/quic/congestion_control/send_algorithm_simulator.h
+++ b/net/quic/congestion_control/send_algorithm_simulator.h
@@ -27,7 +27,11 @@ namespace net {
class SendAlgorithmSimulator {
public:
struct Sender {
- Sender(SendAlgorithmInterface* send_algorithm, RttStats* rtt_stats);
+ Sender(SendAlgorithmInterface* send_algorithm,
+ RttStats* rtt_stats);
+ Sender(SendAlgorithmInterface* send_algorithm,
+ RttStats* rtt_stats,
+ QuicTime::Delta additional_rtt);
void RecordStats() {
QuicByteCount cwnd = send_algorithm->GetCongestionWindow();
@@ -53,6 +57,7 @@ class SendAlgorithmSimulator {
SendAlgorithmInterface* send_algorithm;
RttStats* rtt_stats;
+ QuicTime::Delta additional_rtt;
// Last sequence number the sender sent.
QuicPacketSequenceNumber last_sent;
@@ -72,13 +77,10 @@ class SendAlgorithmSimulator {
};
struct Transfer {
- Transfer(Sender* sender, QuicByteCount num_bytes, QuicTime start_time)
- : sender(sender),
- num_bytes(num_bytes),
- bytes_acked(0),
- bytes_lost(0),
- bytes_in_flight(0),
- start_time(start_time) {}
+ Transfer(Sender* sender,
+ QuicByteCount num_bytes,
+ QuicTime start_time,
+ string name);
Sender* sender;
QuicByteCount num_bytes;
@@ -86,6 +88,7 @@ class SendAlgorithmSimulator {
QuicByteCount bytes_lost;
QuicByteCount bytes_in_flight;
QuicTime start_time;
+ string name;
};
struct SentPacket {
@@ -154,7 +157,8 @@ class SendAlgorithmSimulator {
void AddTransfer(Sender* sender, size_t num_bytes);
// Adds a pending sending to start at the specified time.
- void AddTransfer(Sender* sender, size_t num_bytes, QuicTime start_time);
+ void AddTransfer(
+ Sender* sender, size_t num_bytes, QuicTime start_time, string name);
// Convenience method to transfer all bytes.
void TransferBytes();
« no previous file with comments | « net/quic/congestion_control/send_algorithm_interface.h ('k') | net/quic/congestion_control/send_algorithm_simulator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698