Lines Matching refs:epoch
312 pub fn should_elicit_ack(&self, epoch: packet::Epoch) -> bool { in should_elicit_ack()
313 self.loss_probes[epoch] > 0 || in should_elicit_ack()
319 &mut self, mut pkt: Sent, epoch: packet::Epoch, in on_packet_sent()
333 self.largest_sent_pkt[epoch] = in on_packet_sent()
334 cmp::max(self.largest_sent_pkt[epoch], pkt_num); in on_packet_sent()
338 self.time_of_last_sent_ack_eliciting_pkt[epoch] = Some(now); in on_packet_sent()
341 self.in_flight_count[epoch] += 1; in on_packet_sent()
356 epoch == packet::Epoch::Application && in on_packet_sent()
371 self.schedule_next_packet(epoch, now, sent_bytes); in on_packet_sent()
379 self.sent[epoch].push_back(pkt); in on_packet_sent()
398 &mut self, epoch: packet::Epoch, now: Instant, packet_size: usize, in schedule_next_packet()
405 let is_app = epoch == packet::Epoch::Application; in schedule_next_packet()
421 epoch: packet::Epoch, handshake_status: HandshakeStatus, now: Instant, in on_ack_received()
433 if self.largest_acked_pkt[epoch] == u64::MAX { in on_ack_received()
434 self.largest_acked_pkt[epoch] = largest_acked; in on_ack_received()
436 self.largest_acked_pkt[epoch] = in on_ack_received()
437 cmp::max(self.largest_acked_pkt[epoch], largest_acked); in on_ack_received()
457 let unacked_iter = self.sent[epoch] in on_ack_received()
473 self.largest_acked_pkt[epoch] - unacked.pkt_num + 1; in on_ack_received()
505 self.acked[epoch].extend(unacked.frames.drain(..)); in on_ack_received()
508 self.in_flight_count[epoch] = in on_ack_received()
509 self.in_flight_count[epoch].saturating_sub(1); in on_ack_received()
549 let ack_delay = if epoch == packet::Epoch::Application { in on_ack_received()
564 self.detect_lost_packets(epoch, now, trace_id); in on_ack_received()
566 self.on_packets_acked(newly_acked, epoch, now); in on_ack_received()
572 self.drain_packets(epoch, now); in on_ack_received()
581 let (earliest_loss_time, epoch) = self.loss_time_and_space(); in on_loss_detection_timeout()
586 self.detect_lost_packets(epoch, now, trace_id); in on_loss_detection_timeout()
594 let epoch = if self.bytes_in_flight > 0 { in on_loss_detection_timeout() localVariable
613 self.loss_probes[epoch] = in on_loss_detection_timeout()
616 let unacked_iter = self.sent[epoch] in on_loss_detection_timeout()
623 .take(self.loss_probes[epoch]); in on_loss_detection_timeout()
633 self.lost[epoch].extend_from_slice(&unacked.frames); in on_loss_detection_timeout()
644 &mut self, epoch: packet::Epoch, handshake_status: HandshakeStatus, in on_pkt_num_space_discarded()
647 let unacked_bytes = self.sent[epoch] in on_pkt_num_space_discarded()
656 self.sent[epoch].clear(); in on_pkt_num_space_discarded()
657 self.lost[epoch].clear(); in on_pkt_num_space_discarded()
658 self.acked[epoch].clear(); in on_pkt_num_space_discarded()
660 self.time_of_last_sent_ack_eliciting_pkt[epoch] = None; in on_pkt_num_space_discarded()
661 self.loss_time[epoch] = None; in on_pkt_num_space_discarded()
662 self.loss_probes[epoch] = 0; in on_pkt_num_space_discarded()
663 self.in_flight_count[epoch] = 0; in on_pkt_num_space_discarded()
775 let mut epoch = packet::Epoch::Initial; in loss_time_and_space() localVariable
776 let mut time = self.loss_time[epoch]; in loss_time_and_space()
786 epoch = e; in loss_time_and_space()
790 (time, epoch) in loss_time_and_space()
862 &mut self, epoch: packet::Epoch, now: Instant, trace_id: &str, in detect_lost_packets()
864 let largest_acked = self.largest_acked_pkt[epoch]; in detect_lost_packets()
866 self.loss_time[epoch] = None; in detect_lost_packets()
882 let unacked_iter = self.sent[epoch] in detect_lost_packets()
894 self.lost[epoch].extend(unacked.frames.drain(..)); in detect_lost_packets()
905 self.in_flight_count[epoch] = in detect_lost_packets()
906 self.in_flight_count[epoch].saturating_sub(1); in detect_lost_packets()
912 epoch in detect_lost_packets()
919 let loss_time = match self.loss_time[epoch] { in detect_lost_packets()
926 self.loss_time[epoch] = Some(loss_time); in detect_lost_packets()
933 self.on_packets_lost(lost_bytes, &pkt, epoch, now); in detect_lost_packets()
936 self.drain_packets(epoch, now); in detect_lost_packets()
941 fn drain_packets(&mut self, epoch: packet::Epoch, now: Instant) { in drain_packets()
942 let mut lowest_non_expired_pkt_index = self.sent[epoch].len(); in drain_packets()
954 for (i, pkt) in self.sent[epoch].iter().enumerate() { in drain_packets()
969 self.sent[epoch].drain(..lowest_non_expired_pkt_index); in drain_packets()
973 &mut self, acked: Vec<Acked>, epoch: packet::Epoch, now: Instant, in on_packets_acked()
984 (self.cc_ops.on_packets_acked)(self, &acked, epoch, now); in on_packets_acked()
1005 epoch: packet::Epoch, now: Instant, in on_packets_lost()
1009 self.congestion_event(lost_bytes, largest_lost_pkt.time_sent, epoch, now); in on_packets_lost()
1017 &mut self, lost_bytes: usize, time_sent: Instant, epoch: packet::Epoch, in congestion_event()
1024 (self.cc_ops.congestion_event)(self, lost_bytes, time_sent, epoch, now); in congestion_event()
1106 epoch: packet::Epoch,
1114 epoch: packet::Epoch,