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

Issue 654843007: Cast: Increase UDP socket send buffer size (Closed)

Created:
6 years, 2 months ago by Alpha Left Google
Modified:
6 years, 2 months ago
Reviewers:
hubbe, miu
CC:
chromium-reviews, hclam+watch_chromium.org, cbentzel+watch_chromium.org, imcheng+watch_chromium.org, hguihot+watch_chromium.org, jasonroberts+watch_google.com, avayvod+watch_chromium.org, pwestin+watch_google.com, feature-media-reviews_chromium.org, miu+watch_chromium.org, hubbe+watch_chromium.org, mikhal+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Cast: set UDP socket send buffer size via options On Windows the default UDP send buffer size is 8192. OSX default is 9216. On Linux default is 212992. The values are too small on Windows and OSX. This cannot make good use of the A-MPDU of 802.11n (64KB), which is the most common network for Cast Streaming. We have also seen strong evidence that the default buffer size is limiting, e.g. long packet queuing delay on Windows, p2p socket seeing a lot of EWOULDBLOCKs. This code uses pacer maximum burst size (in bytes) as the send buffer size. Also added an option "send_buffer_min_size" to allow application to choose an even larger value for send buffer size. BUG=423545 Committed: https://crrev.com/482d3eb1b6b8da044304ca4bc89d9c0b0764e218 Cr-Commit-Position: refs/heads/master@{#300183}

Patch Set 1 #

Patch Set 2 : multiply by ip packet size #

Patch Set 3 : move code #

Total comments: 6

Patch Set 4 : options #

Patch Set 5 : fixed compile #

Total comments: 9

Patch Set 6 : vlog to log(warning) #

Total comments: 2

Patch Set 7 : fixed logging #

Unified diffs Side-by-side diffs Delta from patch set Stats (+50 lines, -13 lines) Patch
M media/cast/net/cast_transport_sender_impl.h View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M media/cast/net/cast_transport_sender_impl.cc View 1 2 3 4 5 5 chunks +37 lines, -13 lines 0 comments Download
M media/cast/net/udp_transport.h View 1 2 3 2 chunks +3 lines, -0 lines 0 comments Download
M media/cast/net/udp_transport.cc View 1 2 3 4 5 6 3 chunks +5 lines, -0 lines 0 comments Download
M media/cast/net/udp_transport_unittest.cc View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
M media/cast/test/utility/in_process_receiver.cc View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 16 (3 generated)
miu
Overall, I'm in total agreement with what you're doing here. However, a few concerns: https://codereview.chromium.org/654843007/diff/40001/media/cast/net/cast_transport_sender_impl.cc ...
6 years, 2 months ago (2014-10-15 21:20:21 UTC) #2
hubbe
Smaller buffers could be a more effective way to implement pacing though, larger buffers isn't ...
6 years, 2 months ago (2014-10-15 21:56:04 UTC) #4
Alpha Left Google
On 2014/10/15 21:20:21, miu wrote: > Overall, I'm in total agreement with what you're doing ...
6 years, 2 months ago (2014-10-15 22:28:27 UTC) #5
Alpha Left Google
On 2014/10/15 21:56:04, hubbe wrote: > Smaller buffers could be a more effective way to ...
6 years, 2 months ago (2014-10-15 22:37:11 UTC) #6
Alpha Left Google
Fixed comments by miu@. Also changed to code to allow application to override send buffer ...
6 years, 2 months ago (2014-10-15 23:07:26 UTC) #7
miu
https://codereview.chromium.org/654843007/diff/80001/media/cast/net/cast_transport_sender_impl.cc File media/cast/net/cast_transport_sender_impl.cc (right): https://codereview.chromium.org/654843007/diff/80001/media/cast/net/cast_transport_sender_impl.cc#newcode39 media/cast/net/cast_transport_sender_impl.cc:39: int32 GetTransportSendBufferSize(const base::DictionaryValue& options) { s/int32/int/ and throughout. There's ...
6 years, 2 months ago (2014-10-16 18:31:57 UTC) #8
Alpha Left Google
https://codereview.chromium.org/654843007/diff/80001/media/cast/net/cast_transport_sender_impl.cc File media/cast/net/cast_transport_sender_impl.cc (right): https://codereview.chromium.org/654843007/diff/80001/media/cast/net/cast_transport_sender_impl.cc#newcode39 media/cast/net/cast_transport_sender_impl.cc:39: int32 GetTransportSendBufferSize(const base::DictionaryValue& options) { On 2014/10/16 18:31:57, miu ...
6 years, 2 months ago (2014-10-16 18:41:27 UTC) #9
Alpha Left Google
Ping again about int32 vs int. The reason I chose int32 is because the underlying ...
6 years, 2 months ago (2014-10-17 19:26:37 UTC) #10
miu
lgtm % one thing you will want to change: https://codereview.chromium.org/654843007/diff/100001/media/cast/net/udp_transport.cc File media/cast/net/udp_transport.cc (right): https://codereview.chromium.org/654843007/diff/100001/media/cast/net/udp_transport.cc#newcode237 media/cast/net/udp_transport.cc:237: ...
6 years, 2 months ago (2014-10-17 20:20:43 UTC) #11
Alpha Left Google
https://codereview.chromium.org/654843007/diff/100001/media/cast/net/udp_transport.cc File media/cast/net/udp_transport.cc (right): https://codereview.chromium.org/654843007/diff/100001/media/cast/net/udp_transport.cc#newcode237 media/cast/net/udp_transport.cc:237: LOG(WARNING) << "Failed to send packet: " << result ...
6 years, 2 months ago (2014-10-17 20:24:57 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/654843007/120001
6 years, 2 months ago (2014-10-17 20:26:02 UTC) #14
commit-bot: I haz the power
Committed patchset #7 (id:120001)
6 years, 2 months ago (2014-10-17 22:51:21 UTC) #15
commit-bot: I haz the power
6 years, 2 months ago (2014-10-17 22:51:52 UTC) #16
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/482d3eb1b6b8da044304ca4bc89d9c0b0764e218
Cr-Commit-Position: refs/heads/master@{#300183}

Powered by Google App Engine
This is Rietveld 408576698