Lines Matching full:now
174 fn on_packet_sent(r: &mut Recovery, sent_bytes: usize, now: Instant) { in on_packet_sent()
181 let delta = now - last_sent_time; in on_packet_sent()
194 cubic.last_sent_time = Some(now); in on_packet_sent()
196 reno::on_packet_sent(r, sent_bytes, now); in on_packet_sent()
200 r: &mut Recovery, packets: &[Acked], epoch: packet::Epoch, now: Instant, in on_packets_acked()
203 on_packet_acked(r, pkt, epoch, now); in on_packets_acked()
208 r: &mut Recovery, packet: &Acked, epoch: packet::Epoch, now: Instant, in on_packet_acked()
267 if r.hystart.on_packet_acked(epoch, packet, r.latest_rtt, now) { in on_packet_acked()
293 ca_start_time = now; in on_packet_acked()
294 r.congestion_recovery_start_time = Some(now); in on_packet_acked()
305 let t = now.saturating_duration_since(ca_start_time); in on_packet_acked()
351 epoch: packet::Epoch, now: Instant, in congestion_event()
358 r.congestion_recovery_start_time = Some(now); in congestion_event()
461 r.on_packet_sent_cc(1000, Instant::now()); in cubic_send()
472 let now = Instant::now(); in cubic_slow_start() localVariable
477 time_sent: now, in cubic_slow_start()
484 delivered_time: now, in cubic_slow_start()
485 first_sent_time: now, in cubic_slow_start()
492 r.on_packet_sent_cc(p.size, now); in cubic_slow_start()
502 delivered_time: now, in cubic_slow_start()
503 first_sent_time: now, in cubic_slow_start()
508 r.on_packets_acked(acked, packet::Epoch::Application, now); in cubic_slow_start()
520 let now = Instant::now(); in cubic_slow_start_multi_acks() localVariable
525 time_sent: now, in cubic_slow_start_multi_acks()
532 delivered_time: now, in cubic_slow_start_multi_acks()
533 first_sent_time: now, in cubic_slow_start_multi_acks()
540 r.on_packet_sent_cc(p.size, now); in cubic_slow_start_multi_acks()
551 delivered_time: now, in cubic_slow_start_multi_acks()
552 first_sent_time: now, in cubic_slow_start_multi_acks()
561 delivered_time: now, in cubic_slow_start_multi_acks()
562 first_sent_time: now, in cubic_slow_start_multi_acks()
571 delivered_time: now, in cubic_slow_start_multi_acks()
572 first_sent_time: now, in cubic_slow_start_multi_acks()
578 r.on_packets_acked(acked, packet::Epoch::Application, now); in cubic_slow_start_multi_acks()
590 let now = Instant::now(); in cubic_congestion_event() localVariable
595 now, in cubic_congestion_event()
597 now, in cubic_congestion_event()
611 let mut now = Instant::now(); in cubic_congestion_avoidance() localVariable
616 r.on_packet_sent_cc(r.max_datagram_size, now); in cubic_congestion_avoidance()
622 now, in cubic_congestion_avoidance()
624 now, in cubic_congestion_avoidance()
634 r.update_rtt(rtt, Duration::from_millis(0), now); in cubic_congestion_avoidance()
637 now += rtt; in cubic_congestion_avoidance()
647 time_sent: now, in cubic_congestion_avoidance()
650 delivered_time: now, in cubic_congestion_avoidance()
651 first_sent_time: now, in cubic_congestion_avoidance()
656 r.on_packets_acked(acked, packet::Epoch::Application, now); in cubic_congestion_avoidance()
657 now += rtt; in cubic_congestion_avoidance()
669 let now = Instant::now(); in cubic_collapse_cwnd_and_restart() localVariable
672 r.on_packet_sent_cc(30000, now); in cubic_collapse_cwnd_and_restart()
677 now, in cubic_collapse_cwnd_and_restart()
679 now, in cubic_collapse_cwnd_and_restart()
692 time_sent: now + Duration::from_millis(1), in cubic_collapse_cwnd_and_restart()
695 delivered_time: now, in cubic_collapse_cwnd_and_restart()
696 first_sent_time: now, in cubic_collapse_cwnd_and_restart()
701 r.on_packets_acked(acked, packet::Epoch::Application, now); in cubic_collapse_cwnd_and_restart()
717 let now = Instant::now(); in cubic_hystart_css_to_ss() localVariable
723 time_sent: now, in cubic_hystart_css_to_ss()
730 delivered_time: now, in cubic_hystart_css_to_ss()
731 first_sent_time: now, in cubic_hystart_css_to_ss()
745 r.on_packet_sent_cc(p.size, now); in cubic_hystart_css_to_ss()
752 let now = now + rtt_1st; in cubic_hystart_css_to_ss() localVariable
754 r.update_rtt(rtt_1st, Duration::from_millis(0), now); in cubic_hystart_css_to_ss()
761 delivered_time: now, in cubic_hystart_css_to_ss()
762 first_sent_time: now, in cubic_hystart_css_to_ss()
767 r.on_packets_acked(acked, epoch, now); in cubic_hystart_css_to_ss()
776 let now = now + rtt_2nd; in cubic_hystart_css_to_ss() localVariable
780 r.on_packet_sent_cc(p.size, now); in cubic_hystart_css_to_ss()
791 r.update_rtt(rtt_2nd, Duration::from_millis(0), now); in cubic_hystart_css_to_ss()
798 delivered_time: now, in cubic_hystart_css_to_ss()
799 first_sent_time: now, in cubic_hystart_css_to_ss()
804 r.on_packets_acked(acked, epoch, now); in cubic_hystart_css_to_ss()
811 // Now we are in CSS. in cubic_hystart_css_to_ss()
818 let now = now + rtt_3rd; in cubic_hystart_css_to_ss() localVariable
823 r.on_packet_sent_cc(p.size, now); in cubic_hystart_css_to_ss()
831 r.update_rtt(rtt_3rd, Duration::from_millis(0), now); in cubic_hystart_css_to_ss()
838 delivered_time: now, in cubic_hystart_css_to_ss()
839 first_sent_time: now, in cubic_hystart_css_to_ss()
844 r.on_packets_acked(acked, epoch, now); in cubic_hystart_css_to_ss()
848 // Now we are back in Slow Start. in cubic_hystart_css_to_ss()
865 let now = Instant::now(); in cubic_hystart_css_to_ca() localVariable
871 time_sent: now, in cubic_hystart_css_to_ca()
878 delivered_time: now, in cubic_hystart_css_to_ca()
879 first_sent_time: now, in cubic_hystart_css_to_ca()
893 r.on_packet_sent_cc(p.size, now); in cubic_hystart_css_to_ca()
900 let now = now + rtt_1st; in cubic_hystart_css_to_ca() localVariable
902 r.update_rtt(rtt_1st, Duration::from_millis(0), now); in cubic_hystart_css_to_ca()
909 delivered_time: now, in cubic_hystart_css_to_ca()
910 first_sent_time: now, in cubic_hystart_css_to_ca()
915 r.on_packets_acked(acked, epoch, now); in cubic_hystart_css_to_ca()
924 let now = now + rtt_2nd; in cubic_hystart_css_to_ca() localVariable
928 r.on_packet_sent_cc(p.size, now); in cubic_hystart_css_to_ca()
939 r.update_rtt(rtt_2nd, Duration::from_millis(0), now); in cubic_hystart_css_to_ca()
946 delivered_time: now, in cubic_hystart_css_to_ca()
947 first_sent_time: now, in cubic_hystart_css_to_ca()
952 r.on_packets_acked(acked, epoch, now); in cubic_hystart_css_to_ca()
959 // Now we are in CSS. in cubic_hystart_css_to_ca()
965 let now = now + rtt_css; in cubic_hystart_css_to_ca() localVariable
970 r.on_packet_sent_cc(p.size, now); in cubic_hystart_css_to_ca()
977 r.update_rtt(rtt_css, Duration::from_millis(0), now); in cubic_hystart_css_to_ca()
984 delivered_time: now, in cubic_hystart_css_to_ca()
985 first_sent_time: now, in cubic_hystart_css_to_ca()
990 r.on_packets_acked(acked, epoch, now); in cubic_hystart_css_to_ca()
995 // Now we are in congestion avoidance. in cubic_hystart_css_to_ca()
1005 let now = Instant::now(); in cubic_spurious_congestion_event() localVariable
1010 r.on_packet_sent_cc(r.max_datagram_size, now); in cubic_spurious_congestion_event()
1016 now, in cubic_spurious_congestion_event()
1018 now, in cubic_spurious_congestion_event()
1030 time_sent: now + rtt, in cubic_spurious_congestion_event()
1033 delivered_time: now, in cubic_spurious_congestion_event()
1034 first_sent_time: now, in cubic_spurious_congestion_event()
1040 r.update_rtt(rtt, Duration::from_millis(0), now); in cubic_spurious_congestion_event()
1046 now + rtt + Duration::from_millis(5), in cubic_spurious_congestion_event()
1052 let now = now + rtt; in cubic_spurious_congestion_event() localVariable
1058 now, in cubic_spurious_congestion_event()
1060 now, in cubic_spurious_congestion_event()
1072 time_sent: now + rtt, in cubic_spurious_congestion_event()
1075 delivered_time: now, in cubic_spurious_congestion_event()
1076 first_sent_time: now, in cubic_spurious_congestion_event()
1082 r.update_rtt(rtt, Duration::from_millis(0), now); in cubic_spurious_congestion_event()
1088 now + rtt + Duration::from_millis(5), in cubic_spurious_congestion_event()
1101 let mut now = Instant::now(); in cubic_fast_convergence() localVariable
1106 r.on_packet_sent_cc(r.max_datagram_size, now); in cubic_fast_convergence()
1112 now, in cubic_fast_convergence()
1114 now, in cubic_fast_convergence()
1123 r.update_rtt(rtt, Duration::from_millis(0), now); in cubic_fast_convergence()
1126 now += rtt; in cubic_fast_convergence()
1136 time_sent: now, in cubic_fast_convergence()
1139 delivered_time: now, in cubic_fast_convergence()
1140 first_sent_time: now, in cubic_fast_convergence()
1145 r.on_packets_acked(acked, packet::Epoch::Application, now); in cubic_fast_convergence()
1146 now += rtt; in cubic_fast_convergence()
1153 // Fast convergence: now there is 2nd congestion event and in cubic_fast_convergence()
1158 now, in cubic_fast_convergence()
1160 now, in cubic_fast_convergence()