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

Side by Side Diff: net/quic/quic_sent_packet_manager.cc

Issue 819653006: Attach QuicAckNotifiers to the serialized packet, instead of individual (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@removing_deprecated_flag_83439062
Patch Set: Created 5 years, 11 months 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 unified diff | Download patch
« no previous file with comments | « net/quic/quic_protocol.h ('k') | net/tools/quic/end_to_end_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "net/quic/quic_sent_packet_manager.h" 5 #include "net/quic/quic_sent_packet_manager.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after
460 QuicPacketSequenceNumber newest_transmission = 460 QuicPacketSequenceNumber newest_transmission =
461 transmission_info.all_transmissions == nullptr 461 transmission_info.all_transmissions == nullptr
462 ? sequence_number 462 ? sequence_number
463 : *transmission_info.all_transmissions->rbegin(); 463 : *transmission_info.all_transmissions->rbegin();
464 // This packet has been revived at the receiver. If we were going to 464 // This packet has been revived at the receiver. If we were going to
465 // retransmit it, do not retransmit it anymore. 465 // retransmit it, do not retransmit it anymore.
466 pending_retransmissions_.erase(newest_transmission); 466 pending_retransmissions_.erase(newest_transmission);
467 467
468 // The AckNotifierManager needs to be notified for revived packets, 468 // The AckNotifierManager needs to be notified for revived packets,
469 // since it indicates the packet arrived from the appliction's perspective. 469 // since it indicates the packet arrived from the appliction's perspective.
470 if (transmission_info.retransmittable_frames) { 470 if (FLAGS_quic_attach_ack_notifiers_to_packets ||
471 ack_notifier_manager_.OnPacketAcked( 471 transmission_info.retransmittable_frames) {
472 newest_transmission, delta_largest_observed); 472 ack_notifier_manager_.OnPacketAcked(newest_transmission,
473 delta_largest_observed);
473 } 474 }
474 475
475 unacked_packets_.RemoveRetransmittability(sequence_number); 476 unacked_packets_.RemoveRetransmittability(sequence_number);
476 } 477 }
477 478
478 void QuicSentPacketManager::MarkPacketHandled( 479 void QuicSentPacketManager::MarkPacketHandled(
479 QuicPacketSequenceNumber sequence_number, 480 QuicPacketSequenceNumber sequence_number,
480 const TransmissionInfo& info, 481 const TransmissionInfo& info,
481 QuicTime::Delta delta_largest_observed) { 482 QuicTime::Delta delta_largest_observed) {
482 QuicPacketSequenceNumber newest_transmission = 483 QuicPacketSequenceNumber newest_transmission =
(...skipping 470 matching lines...) Expand 10 before | Expand all | Expand 10 after
953 // Set up a pacing sender with a 1 millisecond alarm granularity, the same as 954 // Set up a pacing sender with a 1 millisecond alarm granularity, the same as
954 // the default granularity of the Linux kernel's FQ qdisc. 955 // the default granularity of the Linux kernel's FQ qdisc.
955 using_pacing_ = true; 956 using_pacing_ = true;
956 send_algorithm_.reset( 957 send_algorithm_.reset(
957 new PacingSender(send_algorithm_.release(), 958 new PacingSender(send_algorithm_.release(),
958 QuicTime::Delta::FromMilliseconds(1), 959 QuicTime::Delta::FromMilliseconds(1),
959 kInitialUnpacedBurst)); 960 kInitialUnpacedBurst));
960 } 961 }
961 962
962 } // namespace net 963 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/quic_protocol.h ('k') | net/tools/quic/end_to_end_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698