OLD | NEW |
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 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
127 } | 127 } |
128 send_algorithm_.reset(SendAlgorithmInterface::Create( | 128 send_algorithm_.reset(SendAlgorithmInterface::Create( |
129 clock_, &rtt_stats_, kBBR, stats_, initial_congestion_window_)); | 129 clock_, &rtt_stats_, kBBR, stats_, initial_congestion_window_)); |
130 } | 130 } |
131 if (config.HasReceivedConnectionOptions() && | 131 if (config.HasReceivedConnectionOptions() && |
132 ContainsQuicTag(config.ReceivedConnectionOptions(), kRENO)) { | 132 ContainsQuicTag(config.ReceivedConnectionOptions(), kRENO)) { |
133 send_algorithm_.reset(SendAlgorithmInterface::Create( | 133 send_algorithm_.reset(SendAlgorithmInterface::Create( |
134 clock_, &rtt_stats_, kReno, stats_, initial_congestion_window_)); | 134 clock_, &rtt_stats_, kReno, stats_, initial_congestion_window_)); |
135 } | 135 } |
136 if (HasClientSentConnectionOption(config, kPACE) || | 136 if (HasClientSentConnectionOption(config, kPACE) || |
137 (FLAGS_quic_allow_bbr && | 137 FLAGS_quic_enable_pacing || |
138 HasClientSentConnectionOption(config, kTBBR))) { | 138 (FLAGS_quic_allow_bbr && HasClientSentConnectionOption(config, kTBBR))) { |
139 EnablePacing(); | 139 EnablePacing(); |
140 } | 140 } |
141 if (HasClientSentConnectionOption(config, k1CON)) { | 141 if (HasClientSentConnectionOption(config, k1CON)) { |
142 send_algorithm_->SetNumEmulatedConnections(1); | 142 send_algorithm_->SetNumEmulatedConnections(1); |
143 } | 143 } |
144 if (HasClientSentConnectionOption(config, kNCON)) { | 144 if (HasClientSentConnectionOption(config, kNCON)) { |
145 n_connection_simulation_ = true; | 145 n_connection_simulation_ = true; |
146 } | 146 } |
147 if (HasClientSentConnectionOption(config, kNTLP)) { | 147 if (HasClientSentConnectionOption(config, kNTLP)) { |
148 max_tail_loss_probes_ = 0; | 148 max_tail_loss_probes_ = 0; |
(...skipping 784 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
933 // Set up a pacing sender with a 1 millisecond alarm granularity, the same as | 933 // Set up a pacing sender with a 1 millisecond alarm granularity, the same as |
934 // the default granularity of the Linux kernel's FQ qdisc. | 934 // the default granularity of the Linux kernel's FQ qdisc. |
935 using_pacing_ = true; | 935 using_pacing_ = true; |
936 send_algorithm_.reset( | 936 send_algorithm_.reset( |
937 new PacingSender(send_algorithm_.release(), | 937 new PacingSender(send_algorithm_.release(), |
938 QuicTime::Delta::FromMilliseconds(1), | 938 QuicTime::Delta::FromMilliseconds(1), |
939 kInitialUnpacedBurst)); | 939 kInitialUnpacedBurst)); |
940 } | 940 } |
941 | 941 |
942 } // namespace net | 942 } // namespace net |
OLD | NEW |