Repository navigation
fix: keep PTOs within the anti-amplification limit - #4098
larseggert wants to merge 2 commits into
Conversation
There was a problem hiding this comment.
🟢 Approval recommended
The focused guards reuse existing budget semantics, and the regression test covers exhaustion with no blocking issues identified.
No open issues 🎉
What changed in this PR
This PR keeps QUIC probe sends within the anti-amplification limit by requiring enough budget for a full MTU.
Changes:
- Apply the existing budget check to timeout and recovery probes.
- Add a regression test covering partial-budget exhaustion.
| File | Description |
|---|---|
neqo-transport/src/recovery/mod.rs |
Guard both probe paths with the budget check. |
neqo-transport/src/connection/tests/handshake.rs |
Test server probe behavior as the amplification budget runs out. |
Review effort: Balanced
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4098 +/- ##
==========================================
- Coverage 97.19% 97.04% -0.15%
==========================================
Files 113 118 +5
Lines 41835 42182 +347
Branches 41835 42182 +347
==========================================
+ Hits 40662 40936 +274
- Misses 1159 1222 +63
- Partials 14 24 +10
Flags with carried forward coverage won't be shown. Click here to find out more.
|
Merging this PR will degrade performance by 2.84%
|
| Mode | Benchmark | BASE |
HEAD |
Efficiency | |
|---|---|---|---|---|---|
| ❌ | Walltime | 1-conn/10_000-parallel-1b-resp (aka. RPS) |
80.4 ms | 85.3 ms | -5.77% |
| ❌ | Walltime | walltime/1000-streams/each-1-bytes |
4.4 ms | 4.6 ms | -4.53% |
| ❌ | Walltime | walltime/10-streams/each-1048576-bytes |
34 ms | 35.2 ms | -3.48% |
| ❌ | CPU Simulation | simulated/pacing-true/same-seed |
58.2 ms | 60.2 ms | -3.22% |
| ❌ | Walltime | walltime/pacing-true/same-seed |
4.3 ms | 4.4 ms | -3.07% |
| ❌ | Walltime | walltime/1-streams/each-4194304-bytes |
12.7 ms | 13 ms | -2.58% |
| ⚡ | Walltime | 1-conn/1-100mb-req (aka. Upload) |
60 ms | 58.3 ms | +3% |
Tip
Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.
Comparing fix-pto-amplification (4c9b93f) with main (0a535c2)
A PTO datagram is sent only if a full MTU still fits.
1ceee6d to
4c9b93f
Compare
Failed Interop TestsQUIC Interop Runner, client vs. server, differences relative to
All resultsSucceeded Interop TestsQUIC Interop Runner, client vs. server neqo-pr as client
neqo-pr as server
Unsupported Interop TestsQUIC Interop Runner, client vs. server neqo-pr as client
neqo-pr as server
|
Benchmark resultsNo significant performance differences relative to a8809b4. All resultstransfer/1-conn/1-100mb-req (aka. Upload)/mtu-1500 time: [59.216 ms 59.263 ms 59.312 ms]
thrpt: [1.6465 GiB/s 1.6478 GiB/s 1.6492 GiB/s]
Found 4 outliers among 100 measurements (4.00%)
1 (1.00%) low mild
2 (2.00%) high mild
1 (1.00%) high severetransfer/1-conn/1-100mb-resp (aka. Download)/mtu-1500 time: [59.358 ms 59.406 ms 59.456 ms]
thrpt: [1.6425 GiB/s 1.6439 GiB/s 1.6452 GiB/s]
Found 2 outliers among 100 measurements (2.00%)
2 (2.00%) high mildtransfer/1-conn/1-1b-resp (aka. HPS)/mtu-1500 time: [3.5433 ms 3.5443 ms 3.5452 ms]
thrpt: [282.07 B/s 282.15 B/s 282.22 B/s]
Found 4 outliers among 100 measurements (4.00%)
1 (1.00%) low mild
2 (2.00%) high mild
1 (1.00%) high severetransfer/1-conn/10_000-parallel-1b-resp (aka. RPS)/mtu-1500 time: [80.884 ms 81.019 ms 81.161 ms]
thrpt: [123.21 Kelem/s 123.43 Kelem/s 123.63 Kelem/s]
Found 4 outliers among 100 measurements (4.00%)
1 (1.00%) low mild
2 (2.00%) high mild
1 (1.00%) high severestreams-flow-controlled/walltime/1-streams/each-4194304-bytes time: [12.485 ms 12.489 ms 12.494 ms]
thrpt: [320.15 MiB/s 320.27 MiB/s 320.40 MiB/s]streams-flow-controlled/walltime/10-streams/each-1048576-bytes time: [34.250 ms 34.265 ms 34.280 ms]
thrpt: [291.72 MiB/s 291.84 MiB/s 291.97 MiB/s]streams/walltime/1-streams/each-1000-bytes time: [156.61 µs 157.22 µs 158.02 µs]
thrpt: [6.0350 MiB/s 6.0657 MiB/s 6.0896 MiB/s]
Found 2 outliers among 100 measurements (2.00%)
2 (2.00%) high mildstreams/walltime/1000-streams/each-1-bytes time: [4.4693 ms 4.4751 ms 4.4806 ms]
thrpt: [217.95 KiB/s 218.22 KiB/s 218.50 KiB/s]
Found 4 outliers among 100 measurements (4.00%)
4 (4.00%) low mildstreams/walltime/1000-streams/each-1000-bytes time: [14.743 ms 14.755 ms 14.768 ms]
thrpt: [64.576 MiB/s 64.632 MiB/s 64.688 MiB/s]
Found 1 outliers among 100 measurements (1.00%)
1 (1.00%) high mildtransfer/walltime/pacing-false/same-seed time: [3.9392 ms 3.9418 ms 3.9443 ms]
thrpt: [1014.1 MiB/s 1014.8 MiB/s 1015.4 MiB/s]transfer/walltime/pacing-false/varying-seeds time: [3.8176 ms 3.8192 ms 3.8212 ms]
thrpt: [1.0223 GiB/s 1.0228 GiB/s 1.0232 GiB/s]
Found 1 outliers among 100 measurements (1.00%)
1 (1.00%) high mildtransfer/walltime/pacing-true/same-seed time: [4.1131 ms 4.1163 ms 4.1201 ms]
thrpt: [970.85 MiB/s 971.76 MiB/s 972.51 MiB/s]transfer/walltime/pacing-true/varying-seeds time: [4.2189 ms 4.2225 ms 4.2269 ms]
thrpt: [946.33 MiB/s 947.32 MiB/s 948.12 MiB/s]Instructions per cycleCriterion reported no significant timing changes. All benchmarks
Profiles for profiler.firefox.com (64)
Download data for |
Client/server transfer resultsPerformance differences relative to a8809b4. Transfer of 33554432 bytes over loopback, min. 100 runs. All unit-less numbers are in milliseconds.
Table above only shows statistically significant changes. See all results below. All resultsTransfer of 33554432 bytes over loopback, min. 100 runs. All unit-less numbers are in milliseconds.
Download data for |
A PTO datagram is sent only if a full MTU still fits.
Stack created with GitHub Stacks CLI • Give Feedback 💬