Welcome! Log In Create A New Profile

Advanced

Re: [PATCH 3 of 4] QUIC: fixed congesion control in GSO mode

Sergey Kandaurov
August 10, 2023 12:22PM
> On 27 Jul 2023, at 16:42, Roman Arutyunyan <arut@nginx.com> wrote:
>
> # HG changeset patch
> # User Roman Arutyunyan <arut@nginx.com>
> # Date 1690450542 -14400
> # Thu Jul 27 13:35:42 2023 +0400
> # Node ID d8a6ec55938e9a4f1a84c825d9c6abe13aa8b791
> # Parent 0d12ada84c168c62e9bae847af2725641da583d0
> QUIC: fixed congesion control in GSO mode.
>
> In non-GSO mode, a datagram is sent if congestion window is not exceeded by the
> time of send. The window could be exceeded by a small amount after the send.
> In GSO mode, congestion window was checked in a similar way, but for all
> concatenated datagrams as a whole. This could result in exceeding congestion
> window by a lot. Now congestion window is checked for every datagram in GSO
> mode as well.
>
> diff --git a/src/event/quic/ngx_event_quic_output.c b/src/event/quic/ngx_event_quic_output.c
> --- a/src/event/quic/ngx_event_quic_output.c
> +++ b/src/event/quic/ngx_event_quic_output.c
> @@ -358,7 +358,7 @@ ngx_quic_create_segments(ngx_connection_
>
> len = ngx_min(segsize, (size_t) (end - p));
>
> - if (len && cg->in_flight < cg->window) {
> + if (len && cg->in_flight + (p - dst) < cg->window) {
>
> n = ngx_quic_output_packet(c, ctx, p, len, len);
> if (n == NGX_ERROR) {

So ngx_quic_commit_send() is called just once all data
is prepared to be sent in ngx_quic_send_segments().

I think the change is good, though it introduces a subtle diff
compared to cg->in_flight check in ngx_quic_create_datagrams(),
now we will need to take into account.

--
Sergey Kandaurov
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
https://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[PATCH 0 of 4] QUIC performance optimizations

Roman Arutyunyan 291 July 27, 2023 08:44AM

[PATCH 1 of 4] QUIC: optimized ACK delay

Roman Arutyunyan 80 July 27, 2023 08:44AM

Re: [PATCH 1 of 4] QUIC: optimized ACK delay

Sergey Kandaurov 57 August 10, 2023 11:50AM

[PATCH 2 of 4] QUIC: always add ACK frame to the queue head

Roman Arutyunyan 82 July 27, 2023 08:44AM

Re: [PATCH 2 of 4] QUIC: always add ACK frame to the queue head

Sergey Kandaurov 68 August 10, 2023 12:04PM

Re: [PATCH 2 of 4] QUIC: always add ACK frame to the queue head

Vladimir Homutov via nginx-devel 66 August 10, 2023 12:28PM

Re: [PATCH 2 of 4] QUIC: always add ACK frame to the queue head

Sergey Kandaurov 82 August 10, 2023 12:38PM

[PATCH 3 of 4] QUIC: fixed congesion control in GSO mode

Roman Arutyunyan 72 July 27, 2023 08:44AM

Re: [PATCH 3 of 4] QUIC: fixed congesion control in GSO mode

Sergey Kandaurov 59 August 10, 2023 12:22PM

[PATCH 4 of 4] QUIC: use sendmmsg() with GSO

Roman Arutyunyan 71 July 27, 2023 08:44AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 186
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready