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

Unified Diff: net/quic/quic_protocol.h

Issue 11416155: Adding transmission times for every QUIC packet received in the AckFrame. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Done Created 8 years, 1 month 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/quic_protocol.h
diff --git a/net/quic/quic_protocol.h b/net/quic/quic_protocol.h
index 25759aa3050923047c36043955be0abdfa8bb59e..a761c0bb8dbcaf86c5e6908e734318fbfa027431 100644
--- a/net/quic/quic_protocol.h
+++ b/net/quic/quic_protocol.h
@@ -6,6 +6,7 @@
#define NET_QUIC_QUIC_PROTOCOL_H_
#include <limits>
+#include <map>
#include <ostream>
#include <utility>
#include <vector>
@@ -168,14 +169,16 @@ typedef base::hash_set<QuicPacketSequenceNumber> SequenceSet;
struct NET_EXPORT_PRIVATE ReceivedPacketInfo {
ReceivedPacketInfo();
~ReceivedPacketInfo();
+
+ void RecordAck(QuicPacketSequenceNumber sequence_number, QuicTime time);
+ bool ContainsAck(QuicPacketSequenceNumber sequence_number) const;
+ void ClearAcksBefore(QuicPacketSequenceNumber least_unacked);
+
// The highest packet sequence number we've received from the peer.
QuicPacketSequenceNumber largest_received;
- // The time at which we received the above packet.
- QuicTime time_received;
- // The set of packets which we're expecting and have not received.
- // This includes any packets between the lowest and largest_received
- // which we have neither seen nor been informed are non-retransmitting.
- SequenceSet missing_packets;
+
+ // The set of all received packets and their arrival times.
jar (doing other things) 2012/11/30 16:50:33 Isn't this really the "trimmed" set? We transmit a
Ian Swett 2012/12/04 21:40:19 Agreed, comment updated in cleanup CL.
+ std::map<QuicPacketSequenceNumber, QuicTime> received_packet_times;
};
struct NET_EXPORT_PRIVATE SentPacketInfo {
@@ -183,9 +186,6 @@ struct NET_EXPORT_PRIVATE SentPacketInfo {
~SentPacketInfo();
// The lowest packet we've sent which is unacked, and we expect an ack for.
QuicPacketSequenceNumber least_unacked;
- // The set of packets between least_unacked and the last packet we have sent
- // which we will not resend.
- SequenceSet non_retransmiting;
};
// Defines for all types of congestion feedback that will be negotiated in QUIC,
@@ -241,14 +241,11 @@ struct NET_EXPORT_PRIVATE CongestionInfo {
struct NET_EXPORT_PRIVATE QuicAckFrame {
QuicAckFrame() {}
+ // Testing convenience method to construct a QuicAckFrame with all packets
+ // from least_unacked to largest_received acked at time_received.
QuicAckFrame(QuicPacketSequenceNumber largest_received,
QuicTime time_received,
- QuicPacketSequenceNumber least_unacked) {
- received_info.largest_received = largest_received;
- received_info.time_received = time_received;
- sent_info.least_unacked = least_unacked;
- congestion_info.type = kNone;
- }
+ QuicPacketSequenceNumber least_unacked);
NET_EXPORT_PRIVATE friend std::ostream& operator<<(std::ostream& os,
const QuicAckFrame& s);

Powered by Google App Engine
This is Rietveld 408576698