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

Unified Diff: net/quic/quic_sent_packet_manager.cc

Issue 112953003: Remove a QUIC test only flag(limit_rto_increase_for_tests) to limit the (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/quic_sent_packet_manager.h ('k') | net/quic/quic_sent_packet_manager_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_sent_packet_manager.cc
diff --git a/net/quic/quic_sent_packet_manager.cc b/net/quic/quic_sent_packet_manager.cc
index 9282038e980aff84d671a514ca13e8739c2d2640..81da4798b2889fb7bbfc8b96e5a38b0f590fd22a 100644
--- a/net/quic/quic_sent_packet_manager.cc
+++ b/net/quic/quic_sent_packet_manager.cc
@@ -21,10 +21,6 @@ using std::min;
// other transmissions.
bool FLAGS_track_retransmission_history = false;
-// A test-only flag to prevent the RTO from backing off when multiple sequential
-// tail drops occur.
-bool FLAGS_limit_rto_increase_for_tests = false;
-
// Do not remove this flag until the Finch-trials described in b/11706275
// are complete.
// If true, QUIC connections will support the use of a pacing algorithm when
@@ -857,8 +853,8 @@ const QuicTime QuicSentPacketManager::GetRetransmissionTime() const {
return QuicTime::Zero();
}
-const QuicTime::Delta
-QuicSentPacketManager::GetCryptoRetransmissionDelay() const {
+const QuicTime::Delta QuicSentPacketManager::GetCryptoRetransmissionDelay()
+ const {
// This is equivalent to the TailLossProbeDelay, but slightly more aggressive
// because crypto handshake messages don't incur a delayed ack time.
int64 delay_ms = max<int64>(kMinHandshakeTimeoutMs,
@@ -879,24 +875,6 @@ const QuicTime::Delta QuicSentPacketManager::GetTailLossProbeDelay() const {
}
const QuicTime::Delta QuicSentPacketManager::GetRetransmissionDelay() const {
- size_t number_retransmissions = consecutive_rto_count_;
- // TODO(ianswett): Remove this flag now that EndToEndTest is no longer flaky.
- if (FLAGS_limit_rto_increase_for_tests) {
- const size_t kTailDropWindowSize = 5;
- const size_t kTailDropMaxRetransmissions = 4;
- if (pending_packets_.size() <= kTailDropWindowSize) {
- // Avoid exponential backoff of RTO when there are only a few packets
- // outstanding. This helps avoid the situation where fake packet loss
- // causes a packet and it's retransmission to be dropped causing
- // test timouts.
- if (number_retransmissions <= kTailDropMaxRetransmissions) {
- number_retransmissions = 0;
- } else {
- number_retransmissions -= kTailDropMaxRetransmissions;
- }
- }
- }
-
QuicTime::Delta retransmission_delay = send_algorithm_->RetransmissionDelay();
if (retransmission_delay.IsZero()) {
// We are in the initial state, use default timeout values.
@@ -905,7 +883,7 @@ const QuicTime::Delta QuicSentPacketManager::GetRetransmissionDelay() const {
}
// Calculate exponential back off.
retransmission_delay = retransmission_delay.Multiply(
- 1 << min<size_t>(number_retransmissions, kMaxRetransmissions));
+ 1 << min<size_t>(consecutive_rto_count_, kMaxRetransmissions));
// TODO(rch): This code should move to |send_algorithm_|.
if (retransmission_delay.ToMilliseconds() < kMinRetransmissionTimeMs) {
« no previous file with comments | « net/quic/quic_sent_packet_manager.h ('k') | net/quic/quic_sent_packet_manager_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698