Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(288)

Issue 2918323002: Add functionality which limits the number of bytes on the network. (Closed)

Created:
3 years, 6 months ago by stefan-webrtc
Modified:
3 years, 4 months ago
CC:
webrtc-reviews_webrtc.org, video-team_agora.io, yujie_mao (webrtc), zhuangzesen_agora.io, zhengzhonghou_agora.io, tterriberry_mozilla.com, mflodman
Target Ref:
refs/heads/master
Project:
webrtc
Visibility:
Public.

Description

Add functionality which limits the number of bytes on the network. The limit is based on the bandwidth delay product, but also adds some additional slack to compensate for the sawtooth-like BWE pattern and the slowness of the encoder rate control. The delay is estimated based on the time from sending a packet until an ack is received. Since acks are received in bursts (feedback is only sent periodically), a min filter is used to estimate the rtt. Whenever the in flight bytes reaches the congestion window, the pacer is paused, which in turn will result in send-side queues growing. Eventually the encoders will be paused as the pacer queue grows large (currently 2 seconds). BUG=webrtc:7926 Review-Url: https://codereview.webrtc.org/2918323002 Cr-Commit-Position: refs/heads/master@{#19289} Committed: https://chromium.googlesource.com/external/webrtc/+/8497fdde43d920ab1f0cc90362534e5493d23abe

Patch Set 1 #

Patch Set 2 : Fix tests. #

Patch Set 3 : Improved cwnd calculation. #

Patch Set 4 : Fix tests. #

Patch Set 5 : Fix lock order inversion. #

Patch Set 6 : Initialize the pause pacer members. #

Patch Set 7 : Fix typo #

Patch Set 8 : Always send some packets. #

Patch Set 9 : Fix padding during pause. #

Patch Set 10 : Rebase. #

Patch Set 11 : Rebase. #

Patch Set 12 : Fix flaky test. #

Patch Set 13 : Fix race. #

Patch Set 14 : Fix test... #

Patch Set 15 : Add test. #

Patch Set 16 : Add field trial. #

Patch Set 17 : Remove BWE filtering. #

Patch Set 18 : . #

Total comments: 25

Patch Set 19 : Rebase #

Patch Set 20 : Comments addressed. #

Total comments: 5

Patch Set 21 : Comments addressed. #

Total comments: 4

Patch Set 22 : Fix test. #

Patch Set 23 : Comments addressed. #

Patch Set 24 : Switch to max-rtt within a feedback message and fix race. #

Total comments: 4

Patch Set 25 : Fix race in test. #

Patch Set 26 : Comment addressed. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+268 lines, -37 lines) Patch
M webrtc/call/call.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 2 chunks +14 lines, -7 lines 0 comments Download
M webrtc/modules/congestion_controller/include/send_side_congestion_controller.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 2 chunks +7 lines, -0 lines 0 comments Download
M webrtc/modules/congestion_controller/send_side_congestion_controller.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 6 chunks +58 lines, -5 lines 0 comments Download
M webrtc/modules/congestion_controller/transport_feedback_adapter.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 3 chunks +6 lines, -0 lines 0 comments Download
M webrtc/modules/congestion_controller/transport_feedback_adapter.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 6 chunks +29 lines, -2 lines 0 comments Download
M webrtc/modules/pacing/paced_sender.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 9 chunks +29 lines, -11 lines 0 comments Download
M webrtc/modules/pacing/paced_sender_unittest.cc View 1 2 3 4 5 6 7 8 2 chunks +14 lines, -6 lines 0 comments Download
M webrtc/modules/remote_bitrate_estimator/include/send_time_history.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 1 chunk +4 lines, -0 lines 0 comments Download
M webrtc/modules/remote_bitrate_estimator/send_time_history.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 2 chunks +20 lines, -0 lines 0 comments Download
M webrtc/video/end_to_end_tests.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 6 chunks +87 lines, -6 lines 0 comments Download

Messages

Total messages: 89 (60 generated)
stefan-webrtc
Initialize the pause pacer members.
3 years, 5 months ago (2017-06-26 12:10:18 UTC) #17
stefan-webrtc
Fix typo
3 years, 5 months ago (2017-06-26 12:10:56 UTC) #18
stefan-webrtc
Rebase.
3 years, 5 months ago (2017-07-03 08:44:29 UTC) #31
stefan-webrtc
Rebase.
3 years, 5 months ago (2017-07-03 08:49:02 UTC) #32
stefan-webrtc
Fix race.
3 years, 5 months ago (2017-07-03 09:41:30 UTC) #33
stefan-webrtc
Fix test...
3 years, 5 months ago (2017-07-03 11:20:26 UTC) #38
stefan-webrtc
This is a first attempt at adding a cwnd to the congestion controller. A different ...
3 years, 5 months ago (2017-07-07 12:43:02 UTC) #47
stefan-webrtc
Any comments on this?
3 years, 4 months ago (2017-08-02 13:37:12 UTC) #48
philipel
https://codereview.webrtc.org/2918323002/diff/340001/webrtc/modules/congestion_controller/send_side_congestion_controller.cc File webrtc/modules/congestion_controller/send_side_congestion_controller.cc (right): https://codereview.webrtc.org/2918323002/diff/340001/webrtc/modules/congestion_controller/send_side_congestion_controller.cc#newcode111 webrtc/modules/congestion_controller/send_side_congestion_controller.cc:111: pause_pacer_(false), I assume you duplicate the paced sender pause ...
3 years, 4 months ago (2017-08-02 15:35:16 UTC) #49
philipel
Also, this congestion window will pretty much force the pacer to pace at the estimated ...
3 years, 4 months ago (2017-08-02 15:39:28 UTC) #50
stefan-webrtc
On 2017/08/02 15:39:28, philipel wrote: > Also, this congestion window will pretty much force the ...
3 years, 4 months ago (2017-08-03 09:23:40 UTC) #51
stefan-webrtc
Comments addressed.
3 years, 4 months ago (2017-08-04 09:45:08 UTC) #52
stefan-webrtc
https://codereview.webrtc.org/2918323002/diff/340001/webrtc/modules/congestion_controller/send_side_congestion_controller.cc File webrtc/modules/congestion_controller/send_side_congestion_controller.cc (right): https://codereview.webrtc.org/2918323002/diff/340001/webrtc/modules/congestion_controller/send_side_congestion_controller.cc#newcode111 webrtc/modules/congestion_controller/send_side_congestion_controller.cc:111: pause_pacer_(false), On 2017/08/02 15:35:15, philipel wrote: > I assume ...
3 years, 4 months ago (2017-08-04 09:50:00 UTC) #53
stefan-webrtc
Giorgi may be interested in reviewing this too.
3 years, 4 months ago (2017-08-04 09:50:41 UTC) #55
philipel
https://codereview.webrtc.org/2918323002/diff/340001/webrtc/modules/pacing/paced_sender.cc File webrtc/modules/pacing/paced_sender.cc (right): https://codereview.webrtc.org/2918323002/diff/340001/webrtc/modules/pacing/paced_sender.cc#newcode481 webrtc/modules/pacing/paced_sender.cc:481: if (packets_->Empty()) { On 2017/08/04 09:50:00, stefan-webrtc wrote: > ...
3 years, 4 months ago (2017-08-04 14:13:04 UTC) #57
stefan-webrtc
Comments addressed.
3 years, 4 months ago (2017-08-04 14:47:05 UTC) #58
stefan-webrtc
https://codereview.webrtc.org/2918323002/diff/380001/webrtc/modules/congestion_controller/send_side_congestion_controller.cc File webrtc/modules/congestion_controller/send_side_congestion_controller.cc (right): https://codereview.webrtc.org/2918323002/diff/380001/webrtc/modules/congestion_controller/send_side_congestion_controller.cc#newcode335 webrtc/modules/congestion_controller/send_side_congestion_controller.cc:335: void SendSideCongestionController::LimitOutstandingBytes( On 2017/08/04 14:13:04, philipel wrote: > More ...
3 years, 4 months ago (2017-08-07 07:37:11 UTC) #59
philipel
lgtm % comments. https://codereview.webrtc.org/2918323002/diff/380001/webrtc/modules/congestion_controller/transport_feedback_adapter.cc File webrtc/modules/congestion_controller/transport_feedback_adapter.cc (right): https://codereview.webrtc.org/2918323002/diff/380001/webrtc/modules/congestion_controller/transport_feedback_adapter.cc#newcode163 webrtc/modules/congestion_controller/transport_feedback_adapter.cc:163: if (feedback_rtt == -1 && packet_feedback.send_time_ms ...
3 years, 4 months ago (2017-08-07 11:39:48 UTC) #64
stefan-webrtc
Fix test.
3 years, 4 months ago (2017-08-07 11:40:18 UTC) #65
stefan-webrtc
Comments addressed.
3 years, 4 months ago (2017-08-07 11:45:12 UTC) #68
stefan-webrtc
https://codereview.webrtc.org/2918323002/diff/400001/webrtc/modules/congestion_controller/transport_feedback_adapter.cc File webrtc/modules/congestion_controller/transport_feedback_adapter.cc (right): https://codereview.webrtc.org/2918323002/diff/400001/webrtc/modules/congestion_controller/transport_feedback_adapter.cc#newcode165 webrtc/modules/congestion_controller/transport_feedback_adapter.cc:165: clock_->TimeInMilliseconds() - packet_feedback.send_time_ms; On 2017/08/07 11:39:48, philipel wrote: > ...
3 years, 4 months ago (2017-08-08 09:28:22 UTC) #69
stefan-webrtc
Philip, after talking to Goergi I decided to update the min rtt estimation to take ...
3 years, 4 months ago (2017-08-09 11:43:44 UTC) #78
stefan-webrtc
On 2017/08/09 11:43:44, stefan-webrtc wrote: > Philip, after talking to Goergi I decided to update ...
3 years, 4 months ago (2017-08-09 11:44:12 UTC) #79
philipel
https://codereview.webrtc.org/2918323002/diff/460001/webrtc/modules/congestion_controller/transport_feedback_adapter.cc File webrtc/modules/congestion_controller/transport_feedback_adapter.cc (right): https://codereview.webrtc.org/2918323002/diff/460001/webrtc/modules/congestion_controller/transport_feedback_adapter.cc#newcode166 webrtc/modules/congestion_controller/transport_feedback_adapter.cc:166: if (feedback_rtt == -1) { Nit: remove if/else statement. ...
3 years, 4 months ago (2017-08-09 11:58:44 UTC) #80
stefan-webrtc
https://codereview.webrtc.org/2918323002/diff/460001/webrtc/modules/congestion_controller/transport_feedback_adapter.cc File webrtc/modules/congestion_controller/transport_feedback_adapter.cc (right): https://codereview.webrtc.org/2918323002/diff/460001/webrtc/modules/congestion_controller/transport_feedback_adapter.cc#newcode166 webrtc/modules/congestion_controller/transport_feedback_adapter.cc:166: if (feedback_rtt == -1) { On 2017/08/09 11:58:43, philipel ...
3 years, 4 months ago (2017-08-09 12:06:12 UTC) #81
terelius
lgtm
3 years, 4 months ago (2017-08-09 12:45:48 UTC) #82
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.webrtc.org/2918323002/500001
3 years, 4 months ago (2017-08-09 12:53:25 UTC) #85
commit-bot: I haz the power
Committed patchset #26 (id:500001) as https://chromium.googlesource.com/external/webrtc/+/8497fdde43d920ab1f0cc90362534e5493d23abe
3 years, 4 months ago (2017-08-09 14:17:47 UTC) #88
stefan-webrtc
3 years, 4 months ago (2017-08-14 08:49:19 UTC) #89
Message was sent while issue was closed.
A revert of this CL (patchset #26 id:500001) has been created in
https://codereview.webrtc.org/3001653002/ by stefan@webrtc.org.

The reason for reverting is: Speculative revert to see if this caused
regressions in android perf tests..

Powered by Google App Engine
This is Rietveld 408576698