Bug 210107

Summary: Bump priority of LibWebRTCAudioModule thread
Product: WebKit Reporter: youenn fablet <youennf>
Component: WebRTCAssignee: youenn fablet <youennf>
Status: RESOLVED FIXED    
Severity: Normal CC: benjamin, cdumez, cmarcelo, eric.carlson, ews-watchlist, glenn, hta, jer.noble, philipj, sergio, tommyw, webkit-bug-importer, youennf
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch
none
Patch for landing
none
Patch for landing none

Description youenn fablet 2020-04-07 06:22:00 PDT
Bump priority of LibWebRTCAudioModule thread.
This thread is responsible to get audio samples and push them to audio renderers.
Comment 1 youenn fablet 2020-04-07 07:09:23 PDT
Created attachment 395676 [details]
Patch
Comment 2 youenn fablet 2020-04-07 07:16:09 PDT
Created attachment 395677 [details]
Patch
Comment 3 youenn fablet 2020-04-09 08:08:52 PDT
Created attachment 395951 [details]
Patch
Comment 4 Eric Carlson 2020-04-09 08:46:54 PDT
Comment on attachment 395951 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=395951&action=review

> Source/WebCore/platform/mediastream/libwebrtc/LibWebRTCAudioModule.cpp:73
>  void LibWebRTCAudioModule::StartPlayoutOnAudioThread()

This name seems wrong now that it is essentially a one-shot. Maybe something like `PullDataOnAudioThread`, or fold maybe the logic into PollFromSource instead?

> Source/WebCore/platform/mediastream/libwebrtc/LibWebRTCAudioModule.cpp:102
> +        char data[(LibWebRTCAudioFormat::sampleByteSize * channels * LibWebRTCAudioFormat::chunkSampleCount)];

Now that the chunk size is constant (for a given channel count), maybe we should use a member variable that is (re)allocated when the number of channels changes?
Comment 5 youenn fablet 2020-04-09 09:04:15 PDT
Created attachment 395960 [details]
Patch for landing
Comment 6 EWS 2020-04-09 12:33:41 PDT
ChangeLog entry in Source/WebCore/ChangeLog contains OOPS!.
Comment 7 youenn fablet 2020-04-09 23:50:21 PDT
Created attachment 396053 [details]
Patch for landing
Comment 8 EWS 2020-04-10 03:02:29 PDT
Committed r259853: <https://trac.webkit.org/changeset/259853>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 396053 [details].
Comment 9 Radar WebKit Bug Importer 2020-04-10 03:03:27 PDT
<rdar://problem/61575334>