Skip to content

fix(moq-congestion): BBR3's ACK aggregation epoch restarts from idle with its delivered bytes - #8806

Merged
kixelated merged 2 commits into
mainfrom
quest/m1/bbr3-references/idle-aggregation
Nov 15, 2026
Merged

kixelated merged 2 commits into
mainfrom
quest/m1/bbr3-references/idle-aggregation

Conversation

@kixelated

@kixelated kixelated commented Nov 15, 2026 •

Copy link
Copy Markdown
Collaborator

Finishes quest/m1/bbr3-references/idle-aggregation.md (file deleted; no other quest links to it).

Summary

handle_restart_from_idle reset extra_acked_interval_start but not extra_acked_delivered, so every resumed burst counted all earlier bursts' bytes as aggregation, and set_cwnd fed the resulting extra_acked back into cwnd. It now zeroes extra_acked_delivered with the interval start, as Linux zeroes ack_epoch_acked on restart. One test, idle_gaps_keep_extra_acked_bounded, sends 28-packet frames every 33 ms (about 8 Mbit/s at 30 fps) over a 20 ms RTT with a serializing bottleneck.

Public API and wire impact

None. Behavior change in moq-congestion's BBR3 only, so no !.

Caused by

  • moq-dev/moq#4921 - ported draft-06's BBRHandleRestartFromIdle, which omits resetting the delivered bytes (found by person, the 2026-11-14 audit).

Validation

  • Before the fix, the new test failed: extra_acked grew by one burst per frame and cwnd reached 20 MB in 600 frames (about 20 s). With the fix it stays at or under one burst (33.6 KB) on every frame and cwnd under 4 bursts.
  • quest gate just check passes (8485 tests).
  • Not run: wire interop (no wire change). The ledger in rs/moq-quic/README.md is left to the epic README's own work, which will list the divergence from draft-06.

Choices a later review can undo

  • The test uses the scripted Sim with a per-packet ACK spread, because a single whole-burst ACK never reproduced the growth (the delay bound reset the epoch each frame). The bound asserted is one burst for extra_acked and four for cwnd.
  • Scoped to the one reset the quest names; idle_restart and extra_acked_filter are untouched.

Models

Size: XS
Implementer: Claude, claude-sonnet-5-5, unknown effort (arm A)

Follow-ups

None.

Review

Rewritten by quest review after each round.

  • Head: 3de8b92

  • Base: origin/main at 64b621a

  • Risk: medium, the base has no RISK.md to name what is always high or customer-facing, so every change is medium

  • Classified: medium by default

  • Reviewer: Codex, gpt-6.1-sol, medium effort

  • Session: 01a1deee-c7ea-7d20-8bbf-72dfcac48d33, round 1

  • Score: 9/10, The focused reset prevents prior bursts from inflating the ACK-aggregation estimate and includes regression coverage, though tests were not run as instructed.

  • Rounds: 1; first round 0; findings 0: fixed 0, refuted 0, open 0

  • Findings: none

kixelated and others added 2 commits November 15, 2026 03:07
…with its delivered bytes

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@kixelated kixelated changed the title BBR3's ACK aggregation estimate stays bounded across idle fix(moq-congestion): BBR3's ACK aggregation epoch restarts from idle with its delivered bytes Nov 15, 2026
@kixelated
kixelated marked this pull request as ready for review November 15, 2026 11:19

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

Reviewed the full diff of both changed files.

  • Epoch reset on idle restart: handle_restart_from_idle now zeroes extra_acked_delivered together with extra_acked_interval_start. This matches Linux zeroing ack_epoch_acked, and it stops earlier bursts' bytes from counting as aggregation and feeding back into cwnd through set_cwnd.
  • Regression test: idle_gaps_keep_extra_acked_bounded sends 28-packet frames every 33 ms over a 20 ms RTT, with ACKs spread per packet. It asserts extra_acked stays at or under one burst and cwnd under four bursts.
  • Quest file removed: idle-aggregation.md is deleted now that the work is done.

A nit, not blocking: the test's doc comment says bursts are "acknowledged whole", but the body spreads the ACKs per packet to model the serializing bottleneck.

Pullfrog  | View workflow run | Using claude-sonnet-5-5 | 𝕏

@coderabbitai

coderabbitai Bot commented Nov 15, 2026

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

On idle restart, Bbr3::handle_restart_from_idle now clears extra_acked_delivered. A new test simulates repeated bursts with idle gaps and checks bounds for extra_acked and the congestion window. The related idle-aggregation document was deleted.

Merge Risk: Minimal · up to 3de8b

This change resets BBR3's ACK-aggregation accounting on idle restart, so earlier bursts no longer inflate later congestion windows. The new test exercises the reset path, and no merge-blocking risk was found.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the change: BBR3's ACK aggregation epoch restarting from idle with its delivered bytes. This matches the code change, which zeroes extra_acked_delivered in handle_restart_from_idle. Th…
Description check Passed The description states the purpose of the change: handle_restart_from_idle reset extra_acked_interval_start but not extra_acked_delivered. It explains the fix, the new test idle_gaps_keep_extra_acked_…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the change: BBR3's ACK aggregation epoch restarting from idle with its delivered bytes. This matches the code change, which zeroes extra_acked_delivered in handle_restart_from_idle. The title is specific and accurate, and it uses the conventional fix(scope) form.

Full details: Description check

Explanation

The description states the purpose of the change: handle_restart_from_idle reset extra_acked_interval_start but not extra_acked_delivered. It explains the fix, the new test idle_gaps_keep_extra_acked_bounded, validation results, and the deleted quest document. This matches the raw summary, which lists the deleted idle-aggregation.md, the BBR3 fix, and the new test.

Finishing Touches

Simplify code

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 6301e5a4-5d7c-4943-9d83-e081bf9a0a23
Commits

Reviewing files that changed from the base of the PR and between 52732a0 and 3de8b92.

Files selected for processing: 2

  • quest/m1/bbr3-references/idle-aggregation.md
  • rs/moq-congestion/src/bbr3/mod.rs
Files with no reviewable changes: 1

  • quest/m1/bbr3-references/idle-aggregation.md

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 0 remain after this review.

@kixelated
kixelated added this pull request to the merge queue Nov 15, 2026
Merged via the queue into main with commit 64fccba Nov 15, 2026
10 checks passed
@kixelated
kixelated deleted the quest/m1/bbr3-references/idle-aggregation branch November 15, 2026 17:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant